changed S16 to int, so that SET_TO_ZERO can be used.