diff options
-rw-r--r-- | sca-java-2.x/trunk/modules/core/src/main/java/org/apache/tuscany/sca/core/context/impl/CallbackServiceReferenceImpl.java | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/sca-java-2.x/trunk/modules/core/src/main/java/org/apache/tuscany/sca/core/context/impl/CallbackServiceReferenceImpl.java b/sca-java-2.x/trunk/modules/core/src/main/java/org/apache/tuscany/sca/core/context/impl/CallbackServiceReferenceImpl.java index e65dd10808..4c206ec5db 100644 --- a/sca-java-2.x/trunk/modules/core/src/main/java/org/apache/tuscany/sca/core/context/impl/CallbackServiceReferenceImpl.java +++ b/sca-java-2.x/trunk/modules/core/src/main/java/org/apache/tuscany/sca/core/context/impl/CallbackServiceReferenceImpl.java @@ -132,7 +132,12 @@ public class CallbackServiceReferenceImpl<B> extends ServiceReferenceImpl<B> { // to model the callback URI. With these changes the binding can just set a CallbackHandler // in the forward message to get the same effect. Some bindings don't do that hence // the various checks - this.resolvedEndpoint = msgContext.getFrom().getCallbackEndpoint(); + this.resolvedEndpoint = null; + + if (msgContext.getFrom() != null){ + resolvedEndpoint = msgContext.getFrom().getCallbackEndpoint(); + } + if (resolvedEndpoint != null){ if (resolvedEndpoint.getBinding() == null){ this.callbackHandler = new CallbackHandler(resolvedEndpoint.getURI()); |