#vulnerable code 
                                void disconnected()
    {
        if (traceScheduledExecutorService != null)
        {
            traceScheduledExecutorService.shutdown();
        }
        synchronized (channels)
        {
            channels.clear();
        }
    } 
                            #location 5 
                            #vulnerability type THREAD_SAFETY_VIOLATION
#fixed code
                                ChannelManager(AsteriskServerImpl server)
    {
        this.server = server;
    }