diff options
| author | Rajith Muditha Attapattu <rajith@apache.org> | 2009-03-24 20:59:03 +0000 |
|---|---|---|
| committer | Rajith Muditha Attapattu <rajith@apache.org> | 2009-03-24 20:59:03 +0000 |
| commit | 0bae821341197c55c1861e3528f2e6a2b5ebb44f (patch) | |
| tree | 68913e53b5c0386293d10345026ca62a1ce1667d /java/common | |
| parent | 001d11d9e53ee2f9217bba412e5c7db141e0db11 (diff) | |
| download | qpid-python-0bae821341197c55c1861e3528f2e6a2b5ebb44f.tar.gz | |
This is a fix for QPID-1773
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@758017 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'java/common')
| -rw-r--r-- | java/common/src/main/java/org/apache/qpid/transport/Session.java | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/java/common/src/main/java/org/apache/qpid/transport/Session.java b/java/common/src/main/java/org/apache/qpid/transport/Session.java index 361db42498..3dca4fc44e 100644 --- a/java/common/src/main/java/org/apache/qpid/transport/Session.java +++ b/java/common/src/main/java/org/apache/qpid/transport/Session.java @@ -559,7 +559,7 @@ public class Session extends SessionInvoker if (isFull(next)) { Waiter w = new Waiter(commands, timeout); - while (w.hasTime() && isFull(next)) + while (w.hasTime() && isFull(next) && state != CLOSED) { if (state == OPEN || state == RESUMING) { @@ -585,6 +585,19 @@ public class Session extends SessionInvoker } } + if (state == CLOSED) + { + ExecutionException exc = getException(); + if (exc != null) + { + throw new SessionException(exc); + } + else + { + throw new SessionClosedException(); + } + } + if (isFull(next)) { throw new SessionException("timed out waiting for completion"); |
