fixed a bug when the most significant byte is zero