Change return value of read_directive_file to operation list
authorJacob Bachmeyer <jcb@gnu.org>
Fri, 21 Oct 2022 03:50:31 +0000 (22:50 -0500)
committerJacob Bachmeyer <jcb@gnu.org>
Fri, 21 Oct 2022 03:50:31 +0000 (22:50 -0500)
Previously, read_directive_file always returned zero or did not return.
We now return an operation list that will eventually replace the global
%info hash.

gatekeeper.pl

index 2c186b5405f6e207578389b0991402583a8ae874..ab9a30ac0fad6fa824f410300b4c103dc85bea4c 100755 (executable)
@@ -1690,7 +1690,7 @@ sub read_directive_file {
     fatal("gpg verification problem: could not extract timestamp",1);
   }
 
-  return 0;
+  return $ops;
 }
 
 sub automake_tests {
@@ -2077,11 +2077,11 @@ foreach my $packet (@packets) { # each list element is an array reference
       }
     }
     # set up the %info variable
-    my $retval = read_directive_file ($directive_file,
+    my $oplist = read_directive_file ($directive_file,
                                      $upload_file,
                                      $directive_only);
 
-    if ($retval == 0) {
+    if ($oplist) {
       # do the work
       execute_commands({directive => $directive_file, upload => $upload_file,
                        sig => $sig_file, directive_only => $directive_only},