Commit ae8f333
Fix PERL_MM_SHEBANG when input script has args
In _fixin_replace_shebang, empty the argument string when
PERL_MM_SHEBANG=relocatable is set in the environment. Previously, if a script
had a shebang such as "#!/usr/bin/env perl" already, it would become
"#!/usr/bin/env perl perl"; on most systems, env will then try to run "perl
perl" and fail. The same issue exists if the script had a shebang with any
arguments.
Note that this occurs with the env utility before perl does its special
argument-list-as-a-string handling. No arguments can be portably preserved when
using this override.1 parent 5ff7f74 commit ae8f333
2 files changed
+2
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
| 8 | + | |
8 | 9 | | |
9 | 10 | | |
10 | 11 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1322 | 1322 | | |
1323 | 1323 | | |
1324 | 1324 | | |
| 1325 | + | |
1325 | 1326 | | |
1326 | 1327 | | |
1327 | 1328 | | |
| |||
0 commit comments