From: mike Date: Fri, 17 Aug 2007 11:08:38 +0000 (+0000) Subject: ALlow arbitrary options to be specified at end of command-line. X-Git-Tag: cpan_1_22~39 X-Git-Url: http://jsfdemo.indexdata.com/cgi-bin?a=commitdiff_plain;h=8478131197998e23055811b971c2f3424a4f7fb8;p=ZOOM-Perl-moved-to-github.git ALlow arbitrary options to be specified at end of command-line. --- diff --git a/samples/zoom/zoomtst1.pl b/samples/zoom/zoomtst1.pl index 2e3e0b3..c2b7f56 100644 --- a/samples/zoom/zoomtst1.pl +++ b/samples/zoom/zoomtst1.pl @@ -1,4 +1,4 @@ -# $Id: zoomtst1.pl,v 1.4 2006-11-02 17:48:26 mike Exp $ +# $Id: zoomtst1.pl,v 1.5 2007-08-17 11:08:38 mike Exp $ # # See ../README for a description of this program. # perl -I../../blib/lib -I../../blib/arch zoomtst1.pl @@ -7,16 +7,23 @@ use strict; use warnings; use ZOOM; -if (@ARGV != 2) { - print STDERR "Usage: $0 target query\n"; +if (@ARGV < 2 || @ARGV %2 == 1) { + print STDERR "Usage: $0 target query [