https://bz.apache.org/SpamAssassin/show_bug.cgi?id=8535

            Bug ID: 8535
           Summary: spamd children exit on every Unix-socket connection on
                    GNU/Hurd
           Product: Spamassassin
           Version: SVN Trunk (Latest Devel Version)
          Hardware: PC
                OS: other
            Status: NEW
          Severity: normal
          Priority: P2
         Component: spamc/spamd
          Assignee: [email protected]
          Reporter: [email protected]
  Target Milestone: Undefined

Created attachment 6238
  --> https://bz.apache.org/SpamAssassin/attachment.cgi?id=6238&action=edit
skip the connected() test for Unix-socket clients

On GNU/Hurd, with spamd listening on a Unix socket, each preforked child exits
with "spamd: respawning server" right after it accepts a connection, and spamc
passes the message through unscanned.

The cause is a call to connected() that was added in bug 5388 to drop TCP
connections that had not completed the accept. It is not needed for a
Unix-socket client. On most platforms it is harmless there, but GNU/Hurd does
not support getpeername(), which connected() calls, on Unix-domain sockets, and
it fails with EOPNOTSUPP. This is the second time the call has broken
Unix-socket mode: in bug 5416, tests failed on Mac OS X because connected()
returned a defined false value there, and I changed the test to check for
undef. Skipping the call to connected() for Unix-socket clients is arguably a
more robust fix that works for all platforms.

The attached patch skips the connected() test for IO::Socket::UNIX clients.

-- 
You are receiving this mail because:
You are the assignee for the bug.

Reply via email to