Merge pull request #6405 from ArtSin/io_read-fix-mrb_raisef-arg

This commit is contained in:
Yukihiro "Matz" Matsumoto
2024-11-05 13:08:42 +09:00
committed by GitHub
+1 -1
View File
@@ -1679,7 +1679,7 @@ io_read(mrb_state *mrb, mrb_value io)
else {
length = mrb_as_int(mrb, len);
if (length < 0) {
mrb_raisef(mrb, E_ARGUMENT_ERROR, "negative length %d given", length);
mrb_raisef(mrb, E_ARGUMENT_ERROR, "negative length %i given", length);
}
if (length == 0) {
return io_reset_outbuf(mrb, outbuf, 0);