fixed bug, short is signed, and will crash when access memory