X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=lib%2Fgetopts.pl;h=a0818d1e3a0a81c1d911315825e97c921da37a9d;hb=42793c05a05499f6592114920af255acb5944481;hp=65909180168a0ab5ccdef0456a3e574f966c2527;hpb=55204971972392ce5a252fbbd6d78b1c48ed70e3;p=p5sagit%2Fp5-mst-13.2.git diff --git a/lib/getopts.pl b/lib/getopts.pl index 6590918..a0818d1 100644 --- a/lib/getopts.pl +++ b/lib/getopts.pl @@ -18,6 +18,7 @@ sub Getopts { if($args[$pos+1] eq ':') { shift(@ARGV); if($rest eq '') { + ++$errs unless @ARGV; $rest = shift(@ARGV); } eval "\$opt_$first = \$rest;";