Buggy code:
protected void addSharedObjectWrapper ( SOWrapper wrapper ) throws Exception { } protected boolean addToLoading ( SOContainer . LoadingSharedObject lso ) { } protected Object checkRemoteCreate ( ID fromID , ID toID , long seq , SharedObjectDescription desc ) throws Exception { } protected void debug ( String msg ) { } protected boolean destroySharedObject ( ID sharedObjectID ) { } public void dispose ( long waittime ) { } protected void dumpStack ( String msg , Throwable e ) { } protected void fireContainerEvent ( IContainerEvent event ) { } protected final void forward ( ID fromID , ID toID , ContainerMessage data ) throws IOException { } protected abstract void forwardExcluding ( ID from , ID excluding , ContainerMessage data ) throws IOException { } protected abstract void forwardToRemote ( ID from , ID to , ContainerMessage data ) throws IOException { } public Object getAdapter ( Class adapter ) { } public Object [ ] getArgsFromProperties ( SharedObjectDescription sd ) { } public String [ ] getArgTypesFromProperties ( SharedObjectDescription sd ) { } protected byte [ ] serializeObject ( Serializable obj ) throws IOException { } protected ClassLoader getClassLoaderForContainer ( ) { } protected ClassLoader getClassLoaderForSharedObject ( SharedObjectDescription sd ) { } public ISharedObjectContainerConfig getConfig ( ) { } public abstract ID getGroupID ( ) { } public ID [ ] getGroupMemberIDs ( ) { } protected Object getGroupMembershipLock ( ) { } public ID getID ( ) { } protected int getMaxGroupMembers ( ) { } protected Thread getNewSharedObjectThread ( ID sharedObjectID , Runnable runnable ) { } protected long getNextSequenceNumber ( ) { } protected ContainerMessage deserializeContainerMessage ( byte [ ] bytes ) throws IOException { } protected IOSGIService getOSGIServiceInterface ( ) { } public ID [ ] getOtherMemberIDs ( ) { } protected ISynchAsynchConnectionEventHandler getReceiver ( ) { } protected ISharedObject getSharedObject ( ID id ) { } protected ID [ ] getSharedObjectIDs ( ) { } public ISharedObjectManager getSharedObjectManager ( ) { } protected ThreadGroup getSharedObjectThreadGroup ( ) { } protected SOWrapper getSharedObjectWrapper ( ID id ) { } protected void handleAsynchIOException ( IOException except , AsynchConnectionEvent e ) { } protected void handleCreateMessage ( ContainerMessage mess ) throws IOException { } protected void handleCreateResponseMessage ( ContainerMessage mess ) throws IOException { } protected abstract void handleLeaveGroupMessage ( ContainerMessage mess ) { } protected void handleSharedObjectDisposeMessage ( ContainerMessage mess ) throws IOException { } protected void handleSharedObjectMessage ( ContainerMessage mess ) throws IOException { } protected void handleUnidentifiedMessage ( ContainerMessage mess ) throws IOException { } protected abstract void handleViewChangeMessage ( ContainerMessage mess ) throws IOException { } protected boolean isClosing ( ) { } public abstract boolean isGroupManager ( ) { } public abstract boolean isGroupServer ( ) { } public abstract void joinGroup ( ID groupID , Object loginData ) throws SharedObjectContainerJoinException { } protected void killConnection ( IConnection conn ) { } public abstract void leaveGroup ( ) { } protected ISharedObject load ( SharedObjectDescription sd ) throws Exception { } protected void log ( String msg ) { } protected void logException ( String msg , Throwable e ) { } protected ThreadGroup makeLoadingThreadGroup ( ) { } protected SOConfig makeNewSharedObjectConfig ( SharedObjectDescription sd , ISharedObject obj ) { } protected SOConfig makeNewRemoteSharedObjectConfig ( ID fromID , SharedObjectDescription sd , ISharedObject obj ) { } protected SOContext makeNewSharedObjectContext ( SOConfig config , IQueueEnqueue queue ) { } protected SOContext makeNewRemoteSharedObjectContext ( SOConfig config , IQueueEnqueue queue ) { } protected SOWrapper makeNewSharedObjectWrapper ( SharedObjectDescription sd , ISharedObject s ) { } protected SOWrapper makeNewRemoteSharedObjectWrapper ( ID fromID , SharedObjectDescription sd , ISharedObject s ) { } protected void memberLeave ( ID target , IConnection conn ) { } protected void moveFromLoadingToActive ( SOWrapper wrap ) { } protected void notifySharedObjectActivated ( ID sharedObjectID ) { } protected void notifySharedObjectDeactivated ( ID sharedObjectID ) { } protected ContainerMessage validateContainerMessage ( Object mess ) { } protected void processAsynch ( AsynchConnectionEvent e ) { } protected abstract ID getIDForConnection ( IAsynchConnection connection ) { } protected void processDisconnect ( DisconnectConnectionEvent e ) { } protected Serializable processSynch ( SynchConnectionEvent e ) throws IOException { } protected abstract void queueContainerMessage ( ContainerMessage mess ) throws IOException { } protected void removeFromLoading ( ID id ) { } public void removeListener ( ISharedObjectContainerListener l ) { } protected boolean removeRemoteMember ( ID remoteMember ) { } protected ISharedObject removeSharedObject ( ID id ) { } protected void sendCreate ( ID sharedObjectID , ID toContainerID , SharedObjectDescription sd ) throws IOException { } protected void sendCreateResponse ( ID homeID , ID sharedObjectID , Throwable t , long identifier ) throws IOException { } protected void sendCreateResponseSharedObjectMessage ( ID toContainerID , ID fromSharedObject , Throwable t , long ident ) throws IOException { } protected ID [ ] sendCreateSharedObjectMessage ( ID toContainerID , SharedObjectDescription sd ) throws IOException { } protected void sendDispose ( ID toContainerID , ID sharedObjectID ) throws IOException { } protected void sendDisposeSharedObjectMessage ( ID toContainerID , ID fromSharedObject ) throws IOException { } protected void sendMessage ( ContainerMessage data ) throws IOException { } protected byte [ ] serializeSharedObjectMessage ( ID sharedObjectID , Object message ) throws IOException { if ( ! ( message instanceof Serializable ) ) throw new NotSerializableException ( ( ( "sharedobjectmessage<seq2seq4repair_space>" + message ) + "<seq2seq4repair_space>not<seq2seq4repair_space>serializable" ) ) ; ByteArrayOutputStream bouts = new ByteArrayOutputStream ( ) ; <START_BUG> IdentifiableObjectOutputStream ioos = new IdentifiableObjectOutputStream ( sharedObjectID , bouts ) ; <END_BUG> ioos . writeObject ( message ) ; return bouts . toByteArray ( ) ; } protected Object deserializeSharedObjectMessage ( byte [ ] bytes ) throws IOException , ClassNotFoundException { } protected void sendMessage ( ID toContainerID , ID sharedObjectID , Object message ) throws IOException { } protected void sendSharedObjectMessage ( ID toContainerID , ID fromSharedObject , Serializable data ) throws IOException { } protected void setIsClosing ( ) { } protected void setMaxGroupMembers ( int max ) { } }

Fix:
IdentifiableObjectOutputStream ioos = new IdentifiableObjectOutputStream ( sharedObjectID . getName ( ) , bouts ) ;