From f8f9abd4005d275bf6591c03ce9deb52d6cfe737 Mon Sep 17 00:00:00 2001 From: rfeng Date: Wed, 25 Jun 2008 04:54:06 +0000 Subject: Fix NPE when the conversationID==null git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@671426 13f79535-47bb-0310-9956-ffa450edef68 --- .../apache/tuscany/sca/core/conversation/ConversationManagerImpl.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'java/sca/modules/core/src/main') diff --git a/java/sca/modules/core/src/main/java/org/apache/tuscany/sca/core/conversation/ConversationManagerImpl.java b/java/sca/modules/core/src/main/java/org/apache/tuscany/sca/core/conversation/ConversationManagerImpl.java index 0aa9430666..8a883f8e15 100644 --- a/java/sca/modules/core/src/main/java/org/apache/tuscany/sca/core/conversation/ConversationManagerImpl.java +++ b/java/sca/modules/core/src/main/java/org/apache/tuscany/sca/core/conversation/ConversationManagerImpl.java @@ -146,7 +146,8 @@ public class ConversationManagerImpl implements ConversationManager { * @see org.apache.tuscany.sca.core.conversation.ConversationManager#getConversation(java.lang.Object) */ public ExtendedConversation getConversation(Object conversationID) { - return conversations.get(conversationID); + // ConcurrentHashMap cannot take null key + return conversationID == null ? null : conversations.get(conversationID); } /** -- cgit v1.2.3