chiark / gitweb /
prefork: Provide PREFORK_CMDINFOS
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Sun, 17 Jul 2022 12:17:04 +0000 (13:17 +0100)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Sun, 21 Aug 2022 20:21:10 +0000 (21:21 +0100)
Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
cprogs/cgi-fcgi-interp.c
cprogs/prefork.h

index 7ed562590fb558b931fb4f5ebf5afab67671713b..3dbfef68f9b3007dfb1ac74975d0c6a2d0997453 100644 (file)
@@ -139,10 +139,7 @@ static int numservers=4, debugmode;
 static int check_interval=300;
 
 const struct cmdinfo cmdinfos[]= {
-  { "help",   0, .call=of_help                                         },
-  { 0, 'g',   1,                    .sassignto= &ident                 },
-  { 0, 'G',   1, .call= ident_addstring                                },
-  { 0, 'E',   1, .call= off_ident_addenv                               },
+  PREFORK_CMDINFOS
   { 0, 'M',   1, .call=of_iassign,  .iassignto= &numservers            },
   { 0, 'D',   0,                    .iassignto= &debugmode,    .arg= 1 },
   { 0, 'c',   1, .call=of_iassign,  .iassignto= &check_interval        },
index 19c3bc1da4eb0da470665ea5bbb27ed0650c1cf4..a2ad102628fc283262064099dd0df1c23c82330f 100644 (file)
@@ -46,6 +46,11 @@ void find_socket_path(void);
 int acquire_lock(void);
 
 extern const struct cmdinfo cmdinfos[];
+#define PREFORK_CMDINFOS \
+  { "help",   0, .call=of_help                                         }, \
+  { 0, 'g',   1,                    .sassignto= &ident                 }, \
+  { 0, 'G',   1, .call= ident_addstring                                }, \
+  { 0, 'E',   1, .call= off_ident_addenv                               },
 
 void process_opts(const char *const **argv_io);