chiark / gitweb /
fix compilation of inotify thing
[inn-innduct.git] / backends / innduct.c
index 897ec37bc3f94a908b6bf1dec19541f2f1bbf891..b829841613d0aa010d7ce43bdd0e0934479a5fe6 100644 (file)
@@ -462,7 +462,7 @@ struct InputFile {
   long autodefer; /* -1 means not doing autodefer */
 
   int counts[art_MaxState][RCI_max];
-  int readcount_ok, readcount_blank, readcount_err;
+  int readcount_ok, readcount_blank, readcount_err, count_nooffer_missing;
   char path[];
 };
 
@@ -1560,7 +1560,7 @@ static int article_check_expired(Article *art /* must be queued, not conn */) {
 
   LIST_REMOVE(art->ipf->queue, art);
   art->missing= 1;
-  art->ipf->counts[art_Unchecked][RC_missing]++;
+  art->ipf->count_nooffer_missing++;
   article_done(art,-1);
   return 1;
 }
@@ -1941,11 +1941,12 @@ static void *peer_rd_ok(oop_source *lp, oop_read *oread, oop_rd_event ev,
 
   switch (code) {
 
-  case 400: PEERBADMSG("peer stopped accepting articles");
   default:  PEERBADMSG("peer sent unexpected message");
 
-  case 503:
-    if (conn_busy) PEERBADMSG("peer timed us out");
+  case 400:
+    if (conn_busy)
+      PEERBADMSG("peer timed us out or stopped accepting articles");
+
     notice("C%d idle connection closed by peer", conn->fd);
     LIST_REMOVE(conns,conn);
     conn_dispose(conn);
@@ -2278,7 +2279,7 @@ static void filemon_method_dump_info(FILE *f) {
   DUMPV("%d",,filemon_inotify_fd);
   DUMPV("%d",,filemon_inotify_wdmax);
   for (i=0; i<filemon_inotify_wdmax; i++)
-    fprintf(f," wd2ipf[%d]=%p\n", i, filemon_inotify_wd2ipf[i],);
+    fprintf(f," wd2ipf[%d]=%p\n", i, filemon_inotify_wd2ipf[i]);
 }
 
 #endif /* HAVE_INOTIFY && !HAVE_FILEMON */
@@ -2667,12 +2668,12 @@ static void notice_processed(InputFile *ipf, int completed,
     : xasprintf("%s","");
 
   info("%s %s%s read=%d (+bl=%d,+err=%d)%s%s"
-       " offered=%d (ch=%d,nc=%d) accepted=%d (ch=%d,nc=%d)"
+       " missing=%d offered=%d (ch=%d,nc=%d) accepted=%d (ch=%d,nc=%d)"
        RESULT_COUNTS(RCI_NOTHING, RCI_TRIPLE_FMT)
        ,
        completed?"completed":"processed", what, spec,
        ipf->readcount_ok, ipf->readcount_blank, ipf->readcount_err,
-       inprog, autodefer,
+       inprog, autodefer, ipf->count_nooffer_missing,
        CNT(Unchecked,sent) + CNT(Unsolicited,sent)
        , CNT(Unchecked,sent), CNT(Unsolicited,sent),
        CNT(Wanted,accepted) + CNT(Unsolicited,accepted)