BufferQueue: fixed compilation bugs