summaryrefslogtreecommitdiff
path: root/dh_getopt.pl
diff options
context:
space:
mode:
authorjoey <joey>1999-08-17 04:48:57 +0000
committerjoey <joey>1999-08-17 04:48:57 +0000
commit268eabec772aee3ac6330bc99d34b4566bda5659 (patch)
tree2b289438b061bb3b6dd1911bcba20e82f9d59adc /dh_getopt.pl
parent0bbd944c8f59e3cab7c4636a54b9df8fbfc8104f (diff)
downloaddebhelper-268eabec772aee3ac6330bc99d34b4566bda5659.tar.gz
r73: Initial Import
Diffstat (limited to 'dh_getopt.pl')
-rwxr-xr-xdh_getopt.pl6
1 files changed, 5 insertions, 1 deletions
diff --git a/dh_getopt.pl b/dh_getopt.pl
index f91a42e0..0c9bba0b 100755
--- a/dh_getopt.pl
+++ b/dh_getopt.pl
@@ -64,7 +64,7 @@ use Getopt::Long;
Getopt::Long::config("bundling");
# Parse options.
-GetOptions(
+$ret=GetOptions(
"v" => \$verbose,
"verbose" => \$verbose,
@@ -113,6 +113,10 @@ GetOptions(
"init-script=s" => \$init_script,
);
+if (!$ret) {
+ $parse_error="exiting with unknown option.";
+}
+
# Check to see if -V was specified. If so, but no parameters were passed,
# the variable will be defined but empty.
if (defined($version_info)) {