fix queue prohibit r/w when empty/full