diff options
| author | Yukihiro "Matz" Matsumoto <[email protected]> | 2020-04-04 11:50:59 +0900 |
|---|---|---|
| committer | Yukihiro "Matz" Matsumoto <[email protected]> | 2020-04-04 11:50:59 +0900 |
| commit | 3cef380b202ded4ec316540e328ca75f06083394 (patch) | |
| tree | bd3840957d64a31cc2192ce93cf37d458bb16287 | |
| parent | 068b16a352bc19a403ac24fe9d2d9b69cabe2e0b (diff) | |
| download | mruby-3cef380b202ded4ec316540e328ca75f06083394.tar.gz mruby-3cef380b202ded4ec316540e328ca75f06083394.zip | |
Revert part of #4959
To prevent infinite loop on errors; reported by @shuujii
| -rw-r--r-- | lib/mruby/build/command.rb | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/lib/mruby/build/command.rb b/lib/mruby/build/command.rb index 3e8b3f57c..2aa7d1851 100644 --- a/lib/mruby/build/command.rb +++ b/lib/mruby/build/command.rb @@ -36,14 +36,9 @@ module MRuby private def _run(options, params={}) - - cmd_string = if NotFoundCommands.key?(@command) - command + ' ' + ( options % params ) - else - build.filename(command) + ' ' + ( options % params ) - end + return sh command + ' ' + ( options % params ) if NotFoundCommands.key? @command begin - sh cmd_string + sh build.filename(command) + ' ' + ( options % params ) rescue RuntimeError NotFoundCommands[@command] = true _run options, params |
