diff options
author | Niels Thykier <niels@thykier.net> | 2011-06-05 00:31:49 +0200 |
---|---|---|
committer | Raphaël Hertzog <hertzog@debian.org> | 2011-06-05 09:01:15 +0200 |
commit | b3d0bb4a4cb8a994d3841912dccd116224498f32 (patch) | |
tree | 685828f6c6b00e393649d181e5d26199465fd05b /scripts | |
parent | 53af7e486a194fb005beb24873e5fb276e84b42c (diff) | |
download | dpkg-b3d0bb4a4cb8a994d3841912dccd116224498f32.tar.gz |
dpkg-vendor: fail on missing parameters for required arguments
Signed-off-by: Raphaël Hertzog <hertzog@debian.org>
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/dpkg-vendor.pl | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/scripts/dpkg-vendor.pl b/scripts/dpkg-vendor.pl index f59f4c633..f1dabe358 100755 --- a/scripts/dpkg-vendor.pl +++ b/scripts/dpkg-vendor.pl @@ -61,11 +61,13 @@ while (@ARGV) { $_ = shift(@ARGV); if (m/^--vendor$/) { $vendor = shift(@ARGV); + usageerr(_g("%s needs a parameter"), $_) unless defined $vendor; } elsif (m/^--(is|derives-from|query)$/) { usageerr(_g("two commands specified: --%s and --%s"), $1, $action) if defined($action); $action = $1; $param = shift(@ARGV); + usageerr(_g("%s needs a parameter"), $_) unless defined $param; } elsif (m/^-(h|-help)$/) { usage(); exit 0; |