NNTPC: Patch to close idle connections more gracefully

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



A trn user here complained that he often lost connections to nntpcached.
Closer investigation showed that the idle timer (default 25 mins) tore
down connections rather abruptly (log error message and exit), and trn
didn't handle this very well. Returning a 503 message (taken more or
less directly from nnrpd) cured the problem. Thanks to Håkon Løvdal for
finding this.

Steinar Haug, Nethelp consulting, sthaug@nethelp.no
----------------------------------------------------------------------
*** nntpcache.c.2	Tue Feb 11 13:46:30 1997
--- nntpcache.c	Sat Feb 15 18:39:01 1997
***************
*** 118,123 ****
--- 118,124 ----
  
  static RETSIGTYPE sigalrm (int sig)
  {
+ 	emitf ("%d Timeout after %s, closing connection.\r\n", NNTP_TEMPERR_VAL, itod(con.idleTimeout));
  	log (("client idled out after %s", itod(con.idleTimeout)));
  	Exit ();
  }


[Index of Archives]     [Yosemite]     [Yosemite Campsites]     [Bugtraq]     [Linux]     [Trn]

Powered by Linux