diff options
| author | Yukihiro "Matz" Matsumoto <[email protected]> | 2020-10-23 15:43:18 +0900 |
|---|---|---|
| committer | GitHub <[email protected]> | 2020-10-23 15:43:18 +0900 |
| commit | 17247c51f2e713b89d84ea329bae83b71f14a431 (patch) | |
| tree | e69229c79156bb32e1cfa084b1a063e38c65116d /mrbgems/mruby-io | |
| parent | fd38b9217dbb1b4357d8973848babd7ba3f25696 (diff) | |
| parent | f0a64329b1cb8156e0d525d003e5d6ff03b7832f (diff) | |
| download | mruby-17247c51f2e713b89d84ea329bae83b71f14a431.tar.gz mruby-17247c51f2e713b89d84ea329bae83b71f14a431.zip | |
Merge pull request #5099 from dearblue/getargs-array
Prohibit array changes by "a"/"*" specifier of `mrb_get_args()`
Diffstat (limited to 'mrbgems/mruby-io')
| -rw-r--r-- | mrbgems/mruby-io/src/file.c | 4 | ||||
| -rw-r--r-- | mrbgems/mruby-io/src/io.c | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/mrbgems/mruby-io/src/file.c b/mrbgems/mruby-io/src/file.c index d272cab7d..ab325195c 100644 --- a/mrbgems/mruby-io/src/file.c +++ b/mrbgems/mruby-io/src/file.c @@ -115,7 +115,7 @@ mrb_file_s_umask(mrb_state *mrb, mrb_value klass) static mrb_value mrb_file_s_unlink(mrb_state *mrb, mrb_value obj) { - mrb_value *argv; + const mrb_value *argv; mrb_value pathv; mrb_int argc, i; char *path; @@ -533,7 +533,7 @@ static mrb_value mrb_file_s_chmod(mrb_state *mrb, mrb_value klass) { mrb_int mode; mrb_int argc, i; - mrb_value *filenames; + const mrb_value *filenames; int ai = mrb_gc_arena_save(mrb); mrb_get_args(mrb, "i*", &mode, &filenames, &argc); diff --git a/mrbgems/mruby-io/src/io.c b/mrbgems/mruby-io/src/io.c index 0fa0f34b1..d4505e4f7 100644 --- a/mrbgems/mruby-io/src/io.c +++ b/mrbgems/mruby-io/src/io.c @@ -1154,7 +1154,7 @@ mrb_io_s_pipe(mrb_state *mrb, mrb_value klass) static mrb_value mrb_io_s_select(mrb_state *mrb, mrb_value klass) { - mrb_value *argv; + const mrb_value *argv; mrb_int argc; mrb_value read, read_io, write, except, timeout, list; struct timeval *tp, timerec; |
