chiark / gitweb /
with-lock-ex: Convert to MIT
[chiark-utils.git] / cprogs / cgi-fcgi-interp.c
index 93f691ea6670ab3acdc990eb24f48c6c337a2d61..63db94b35fed7a1d3afb3f11c96858a31d3c70d7 100644 (file)
@@ -441,12 +441,12 @@ static bool stab_isnewer(const struct stat *a, const struct stat *b) {
     fprintf(stderr,"stab_isnewer mtime %lu %lu\n",
            (unsigned long)a->st_mtime,
            (unsigned long)b->st_mtime);
-  return a->st_mtime > &b->st_mtime;
+  return a->st_mtime > b->st_mtime;
 }
 
 static void stab_mtimenow(struct stat *out) {
   out->st_mtime = time(NULL);
-  if (baseline_time.st_mtime == (time_t)-1) diee("(stage2) time()");
+  if (out->st_mtime == (time_t)-1) diee("(stage2) time()");
   if (debugmode)
     fprintf(stderr,"stab_mtimenow mtime %lu\n",
            (unsigned long)out->st_mtime);
@@ -604,7 +604,6 @@ int main(int argc, const char *const *argv) {
 
   script = *argv++;
   if (!script) badusage("need script argument");
-  if (*argv) badusage("too many arguments");
 
   if (!stage2) {