More deque fixes