summaryrefslogtreecommitdiff
path: root/eg/nih
diff options
context:
space:
mode:
Diffstat (limited to 'eg/nih')
-rw-r--r--eg/nih5
1 files changed, 3 insertions, 2 deletions
diff --git a/eg/nih b/eg/nih
index 2066f4bd06..4475c499da 100644
--- a/eg/nih
+++ b/eg/nih
@@ -1,4 +1,4 @@
-eval "exec /usr/bin/perl -Spi.bak $0 $*"
+eval 'exec /usr/bin/perl -Spi.bak $0 ${1+"$@"}'
if $running_under_some_shell;
# $RCSfile: nih,v $$Revision: 4.1 $$Date: 92/08/07 17:20:27 $
@@ -6,5 +6,6 @@ eval "exec /usr/bin/perl -Spi.bak $0 $*"
# This script makes #! scripts directly executable on machines that don't
# support #!. It edits in place any scripts mentioned on the command line.
-s|^#!(.*)|#!$1\neval "exec $1 -S \$0 \$*"\n\tif \$running_under_some_shell;|
+s[^#!(.*)]
+ [#!$1\neval 'exec $1 -S \$0 \${1+"\$@"}'\n\tif \$running_under_some_shell;]
if $. == 1;