chiark / gitweb /
dgit-repos-server: Prepare for modes which take arguments
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Fri, 5 Jul 2019 15:44:30 +0000 (16:44 +0100)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Sat, 6 Jul 2019 14:58:10 +0000 (15:58 +0100)
Currently none do.  Both the existing mode_ subroutines check @ARGV,
so this has no overall change other than to error messages.

Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
infra/dgit-repos-server

index 61a4b1739a48f4486dfc7e781266fc855d8f0d4b..2fa9090a26883a44b24ebc61eb620c571b0a161d 100755 (executable)
@@ -1155,7 +1155,7 @@ sub parseargsdispatch () {
 
     $ENV{"DGIT_DRS_\U$_"} = ${ $main::{$_} } foreach @hookenvs;
 
-    die unless @ARGV==1;
+    die unless @ARGV>=1;
 
     my $mode = shift @ARGV;
     die unless $mode =~ m/^--(\w+)$/;