Buggy code:
public class XMPPContainer extends ClientSOContainer implements IPresenceService { public static final int DEFAULT_KEEPALIVE = 30000 ; public static final String CONNECT_NAMESPACE = XmppPlugin . getDefault ( ) . getNamespaceIdentifier ( ) ; public static final String CONTAINER_HELPER_ID = ( XMPPContainer . class . getName ( ) ) + ".xmpphandler" ; protected static final String GOOGLE_SERVICENAME = "gmail.com" ; private static final String [ ] googleHosts = new String [ ] { XMPPContainer . GOOGLE_SERVICENAME , "talk.google.com" , "googlemail.com" } ; public static final String XMPP_GOOGLE_OVERRIDE_PROP_NAME = "ecf.xmpp.google.override" ; private static Set googleNames = new HashSet ( ) ; protected int keepAlive = 0 ; XMPPContainerAccountManager accountManager = null ; XMPPChatRoomManager chatRoomManager = null ; XMPPOutgoingFileTransferHelper outgoingFileTransferContainerAdapter = null ; XMPPContainerPresenceHelper presenceHelper = null ; XMPPUserSearchManager searchManager = null ; protected ID presenceHelperID = null ; protected XMPPContainer ( SOContainerConfig config , int keepAlive ) throws Exception { } public XMPPContainer ( ) throws Exception { } public XMPPContainer ( int ka ) throws Exception { } public XMPPContainer ( String userhost , int ka ) throws Exception { } protected boolean verifySharedObjectMessageTarget ( ID containerID ) { } protected void sendMessage ( ContainerMessage data ) throws IOException { synchronized ( getConnectLock ( ) ) { ID connectedID = getConnectedID ( ) ; if ( connectedID == null ) throw new ConnectException ( "Container<seq2seq4repair_space>not<seq2seq4repair_space>connected" ) ; synchronized ( getGroupMembershipLock ( ) ) { <START_BUG> if ( connectedID . equals ( data . getToContainerID ( ) ) ) <END_BUG> queueContainerMessage ( data ) ; } } } public IRosterManager getRosterManager ( ) { } public IUserSearchManager getUserSearchManager ( ) { } public IAccountManager getAccountManager ( ) { } public IChatRoomManager getChatRoomManager ( ) { } public IChatManager getChatManager ( ) { } public Namespace getConnectNamespace ( ) { } public void connect ( ID remote , IConnectContext joinContext ) throws ContainerConnectException { } public void disconnect ( ) { } public void dispose ( ) { } public Object getAdapter ( Class clazz ) { } private String trimResourceFromJid ( String jid ) { } private void resetTargetResource ( ID originalTarget , Object serverData ) { } protected ID handleConnectResponse ( ID originalTarget , Object serverData ) throws Exception { } protected ISynchAsynchConnection createConnection ( ID remoteSpace , Object data ) throws ConnectionCreateException { } protected boolean isGoogle ( ID remoteSpace ) { } protected Object getConnectData ( ID remote , IConnectContext joinContext ) throws IOException , UnsupportedCallbackException { } protected Object createConnectData ( ID target , Callback [ ] cbs , Object data ) { } protected Callback [ ] createAuthorizationCallbacks ( ) { } protected int getConnectTimeout ( ) { } protected Roster getRoster ( ) throws IOException { } protected void deliverEvent ( Event evt ) { } protected void handleXMPPMessage ( Packet aPacket ) throws IOException { } protected boolean handleAsExtension ( Packet packet ) { } protected SOContext createSharedObjectContext ( SOConfig soconfig , IQueueEnqueue queue ) { } protected void processAsynch ( AsynchEvent e ) { } public ECFConnection getECFConnection ( ) { } public XMPPConnection getXMPPConnection ( ) { } protected void log ( String msg , Throwable e ) { } }

Fix:
if ( ! ( connectedID . equals ( data . getToContainerID ( ) ) ) )