Fixed the construction of ThreadedQueue.