summaryrefslogtreecommitdiff
path: root/lib/getopt.pl
diff options
context:
space:
mode:
authorLarry Wall <lwall@netlabs.com>1991-11-05 09:55:53 +0000
committerLarry Wall <lwall@netlabs.com>1991-11-05 09:55:53 +0000
commit55204971972392ce5a252fbbd6d78b1c48ed70e3 (patch)
treea0fc0fa7a40dae3b455667572b9aac94b020c246 /lib/getopt.pl
parentde3bb51191e884300caf98892ecfcc0ca3ebc09c (diff)
downloadperl-55204971972392ce5a252fbbd6d78b1c48ed70e3.tar.gz
perl 4.0 patch 18: patch #11, continued
See patch #11.
Diffstat (limited to 'lib/getopt.pl')
-rw-r--r--lib/getopt.pl4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/getopt.pl b/lib/getopt.pl
index da39d3b29d..b9d7b5b75b 100644
--- a/lib/getopt.pl
+++ b/lib/getopt.pl
@@ -1,4 +1,4 @@
-;# $Header: getopt.pl,v 4.0 91/03/20 01:25:11 lwall Locked $
+;# $RCSfile: getopt.pl,v $$Revision: 4.0.1.1 $$Date: 91/11/05 17:53:01 $
;# Process single-character switches with switch clustering. Pass one argument
;# which is a string containing all switches that take an argument. For each
@@ -14,7 +14,7 @@ sub Getopt {
local($_,$first,$rest);
local($[) = 0;
- while (($_ = $ARGV[0]) =~ /^-(.)(.*)/) {
+ while (@ARGV && ($_ = $ARGV[0]) =~ /^-(.)(.*)/) {
($first,$rest) = ($1,$2);
if (index($argumentative,$first) >= $[) {
if ($rest ne '') {