add stop handling for tcp listeners