Commit 706ef133 authored by Masaki Muranaka's avatar Masaki Muranaka

Don't ignore the return value of symlink().

parent 083cd9ca
......@@ -112,7 +112,9 @@ static mrb_value
mrb_io_test_file_setup(mrb_state *mrb, mrb_value self)
{
mrb_value ary = mrb_io_test_io_setup(mrb, self);
symlink("/usr/bin", "test-bin");
if (symlink("/usr/bin", "test-bin") == -1) {
mrb_raise(mrb, E_RUNTIME_ERROR, "can't make a symbolic link");
}
return ary;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment