Replace write_int32 with put_int32 for JRuby