[exim-cvs] cvs commit: exim/exim-doc/doc-txt ChangeLog exim…

Startseite
Nachricht löschen
Nachricht beantworten
Autor: Philip Hazel
Datum:  
To: exim-cvs
Betreff: [exim-cvs] cvs commit: exim/exim-doc/doc-txt ChangeLog exim/exim-src/src daemon.c
ph10 2006/09/05 15:14:32 BST

  Modified files:
    exim-doc/doc-txt     ChangeLog 
    exim-src/src         daemon.c 
  Log:
  Ignore EPIPE as well as ECONNECT when closing down an SMTP session in
  the daemon, since dropped connections can show as EPIPE in Solaris.


  Revision  Changes    Path
  1.388     +8 -0      exim/exim-doc/doc-txt/ChangeLog
  1.16      +6 -5      exim/exim-src/src/daemon.c


  Index: ChangeLog
  ===================================================================
  RCS file: /home/cvs/exim/exim-doc/doc-txt/ChangeLog,v
  retrieving revision 1.387
  retrieving revision 1.388
  diff -u -r1.387 -r1.388
  --- ChangeLog    5 Sep 2006 13:24:10 -0000    1.387
  +++ ChangeLog    5 Sep 2006 14:14:32 -0000    1.388
  @@ -1,4 +1,4 @@
  -$Cambridge: exim/exim-doc/doc-txt/ChangeLog,v 1.387 2006/09/05 13:24:10 ph10 Exp $
  +$Cambridge: exim/exim-doc/doc-txt/ChangeLog,v 1.388 2006/09/05 14:14:32 ph10 Exp $


   Change log file for Exim from version 4.21
   -------------------------------------------
  @@ -22,6 +22,14 @@
         Whatever the result of the callout, the value of the domain cache is
         left unchanged (for any other kind of callout, getting as far as trying
         RCPT means that the domain itself is ok).
  +
  +PH/02 Tidied a number of unused variable and signed/unsigned warnings that
  +      gcc 4.1.1 threw up.
  +
  +PH/03 On Solaris, an unexpectedly close socket (dropped connection) can
  +      manifest itself as EPIPE rather than ECONNECT. When tidying away a
  +      session, the daemon ignores ECONNECT errors and logs others; it now
  +      ignores EPIPE as well.



Exim version 4.63

  Index: daemon.c
  ===================================================================
  RCS file: /home/cvs/exim/exim-src/src/daemon.c,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -r1.15 -r1.16
  --- daemon.c    22 Feb 2006 14:46:44 -0000    1.15
  +++ daemon.c    5 Sep 2006 14:14:32 -0000    1.16
  @@ -1,4 +1,4 @@
  -/* $Cambridge: exim/exim-src/src/daemon.c,v 1.15 2006/02/22 14:46:44 ph10 Exp $ */
  +/* $Cambridge: exim/exim-src/src/daemon.c,v 1.16 2006/09/05 14:14:32 ph10 Exp $ */


   /*************************************************
   *     Exim - an Internet mail transport agent    *
  @@ -680,13 +680,14 @@
   /* Close the streams associated with the socket which will also close the
   socket fds in this process. We can't do anything if fclose() fails, but
   logging brings it to someone's attention. However, "connection reset by peer"
  -isn't really a problem, so skip that one. If the streams don't exist, something
  -went wrong while setting things up. Make sure the socket descriptors are
  -closed, in order to drop the connection. */
  +isn't really a problem, so skip that one. On Solaris, a dropped connection can
  +manifest itself as a broken pipe, so drop that one too. If the streams don't
  +exist, something went wrong while setting things up. Make sure the socket
  +descriptors are closed, in order to drop the connection. */


   if (smtp_out != NULL)
     {
  -  if (fclose(smtp_out) != 0 && errno != ECONNRESET)
  +  if (fclose(smtp_out) != 0 && errno != ECONNRESET && errno != EPIPE)
       log_write(0, LOG_MAIN|LOG_PANIC, "daemon: fclose(smtp_out) failed: %s",
         strerror(errno));
     smtp_out = NULL;
  @@ -695,7 +696,7 @@


   if (smtp_in != NULL)
     {
  -  if (fclose(smtp_in) != 0 && errno != ECONNRESET)
  +  if (fclose(smtp_in) != 0 && errno != ECONNRESET && errno != EPIPE)
       log_write(0, LOG_MAIN|LOG_PANIC, "daemon: fclose(smtp_in) failed: %s",
         strerror(errno));
     smtp_in = NULL;