diff options
author | seki <seki@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2002-11-21 14:38:37 +0000 |
---|---|---|
committer | seki <seki@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2002-11-21 14:38:37 +0000 |
commit | e97af583f711f138605a22d88e6d04b017257ec8 (patch) | |
tree | 615249bbf1ea11cc59b87b2d55c76c6cbff3f2e5 /bin | |
parent | f80af5150a37dee92efea2c24d32701fcd95cfe6 (diff) |
* bin/erb: fix -S 4 option bug.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3073 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/erb | 8 |
1 files changed, 3 insertions, 5 deletions
@@ -60,7 +60,7 @@ class ERB require ARGV.req_arg when '-S' # sacurity level arg = ARGV.req_arg - raise "invalid security level #{arg.dump}" unless arg =~ /^[0-3]$/ + raise "invalid safe_level #{arg.dump}" unless arg =~ /^[0-4]$/ safe_level = arg.to_i when '-T' # trim mode arg = ARGV.req_arg @@ -99,7 +99,7 @@ class ERB -d set $DBEUG to true -r [library] load a library -K [kcode] specify KANJI code-set - -S [safe_level] set $SAFE (0..3) + -S [safe_level] set $SAFE (0..4) -T [trim_mode] specify trim_mode (0..2) -P disregard the lin which starts in "%" EOU @@ -121,7 +121,7 @@ EOU puts erb.src end else - erb.run + erb.run(TOPLEVEL_BINDING.taint) end end module_function :run @@ -131,5 +131,3 @@ end if __FILE__ == $0 ERB::Main.run end - - |