1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

sample/iseq_loader: use File.open instead of Kernel#open

This makes auditing for inadvertant command execution
easier.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61790 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
normal 2018-01-12 09:31:22 +00:00
parent 6ef345ab22
commit 3f059374b8

View file

@ -141,11 +141,11 @@ class RubyVM::InstructionSequence
end
def read_compiled_iseq fname, iseq_key
open(iseq_key, 'rb'){|f| f.read}
File.open(iseq_key, 'rb'){|f| f.read}
end
def write_compiled_iseq fname, iseq_key, binary
open(iseq_key, 'wb'){|f| f.write(binary)}
File.open(iseq_key, 'wb'){|f| f.write(binary)}
end
end