def dontListen(thread_id=None):
 global oscThreads
 if (thread_id and (thread_id in oscThreads)):
  ids = [thread_id]
 else:
  ids = list(oscThreads.keys())
 for thread_id in ids:
  Logger.debug(('OSC: Stop thread <%s>' % thread_id))
  oscThreads[thread_id].isRunning = False
  oscThreads[thread_id].join()
  Logger.debug(('OSC: Stop thread <%s> finished' % thread_id))
  del oscThreads[thread_id]

def dontListen ( thread_id = None ) : global oscThreads if ( thread_id and ( thread_id in oscThreads ) ) : ids = [ thread_id ] else : ids = list ( oscThreads . keys ( ) ) for thread_id in ids : Logger . debug ( ( 'OSC: Stop thread <%s>' % thread_id ) ) oscThreads [ thread_id ] . isRunning = False oscThreads [ thread_id ] . join ( ) Logger . debug ( ( 'OSC: Stop thread <%s> finished' % thread_id ) ) del oscThreads [ thread_id ]
closes the socket and kills the thread .