fixed a small bug in bit plane coder bounds checking