summaryrefslogtreecommitdiff
path: root/java/src/IceInternal/ThreadPool.java
diff options
context:
space:
mode:
authorBernard Normier <bernard@zeroc.com>2009-01-23 17:07:21 -0500
committerBernard Normier <bernard@zeroc.com>2009-01-23 17:07:21 -0500
commit2380e089401d048490da23bc6d71e5687bafbe47 (patch)
tree6d97052d1f93bc2bafcd7fd1a9ebe103544b6cad /java/src/IceInternal/ThreadPool.java
parentFixed permissions (diff)
parent3.3.1 third-party updates (diff)
downloadice-2380e089401d048490da23bc6d71e5687bafbe47.tar.bz2
ice-2380e089401d048490da23bc6d71e5687bafbe47.tar.xz
ice-2380e089401d048490da23bc6d71e5687bafbe47.zip
Merge branch 'R3_3_branch' of cvs:/home/git/ice into R3_3_branch
Conflicts: java/resources/IceGridAdmin/icegridadmin_content_dyn.html java/resources/IceGridAdmin/icegridadmin_content_static.html
Diffstat (limited to 'java/src/IceInternal/ThreadPool.java')
-rw-r--r--java/src/IceInternal/ThreadPool.java18
1 files changed, 15 insertions, 3 deletions
diff --git a/java/src/IceInternal/ThreadPool.java b/java/src/IceInternal/ThreadPool.java
index 6f19615ecf0..ea80b046a77 100644
--- a/java/src/IceInternal/ThreadPool.java
+++ b/java/src/IceInternal/ThreadPool.java
@@ -1,6 +1,6 @@
// **********************************************************************
//
-// Copyright (c) 2003-2008 ZeroC, Inc. All rights reserved.
+// Copyright (c) 2003-2009 ZeroC, Inc. All rights reserved.
//
// This copy of Ice is licensed to you under the terms described in the
// ICE_LICENSE file included in this distribution.
@@ -524,6 +524,8 @@ public final class ThreadPool
}
catch(Ice.DatagramLimitException ex) // Expected.
{
+ handler._stream.pos(0);
+ handler._stream.resize(0, true);
continue;
}
catch(Ice.SocketException ex)
@@ -548,6 +550,8 @@ public final class ThreadPool
_instance.initializationData().logger.warning(
"datagram connection exception:\n" + ex + "\n" + handler.toString());
}
+ handler._stream.pos(0);
+ handler._stream.resize(0, true);
}
else
{
@@ -718,6 +722,16 @@ public final class ThreadPool
{
BasicStream stream = handler._stream;
+ if(stream.pos() >= Protocol.headerSize)
+ {
+ if(!handler.read(stream))
+ {
+ return false;
+ }
+ assert(stream.pos() == stream.size());
+ return true;
+ }
+
if(stream.size() == 0)
{
stream.resize(Protocol.headerSize, true);
@@ -805,8 +819,6 @@ public final class ThreadPool
_instance.initializationData().logger.warning("DatagramLimitException: maximum size of "
+ stream.pos() + " exceeded");
}
- stream.pos(0);
- stream.resize(0, true);
throw new Ice.DatagramLimitException();
}
else