Detached dequeue thread from main