$NetBSD: patch-ac,v 1.11 2005/03/22 10:43:50 cjs Exp $ See http://archives.neohapsis.com/archives/postfix/2004-08/1114.html and the preceding thread. Fixes "smtp killed by signal 11" problems. --- src/util/vstream.c.old 2005-03-22 19:04:49.000000000 +0900 +++ src/util/vstream.c 2005-03-22 19:05:26.000000000 +0900 @@ -926,6 +926,10 @@ * policies. Either this, or the vstream*open() routines would have to * have a really ugly interface with lots of mostly-unused arguments (can * you say VMS?). + * + * Initialize the I/O time (as documented) so that a time sensitive, "write + * before read" application does not force flush the first data written + * to a stream, potentially triggering NAGLE delays or other trouble. */ stream = (VSTREAM *) mymalloc(sizeof(*stream)); stream->fd = fd; @@ -939,7 +943,7 @@ stream->timeout = 0; stream->context = 0; stream->jbuf = 0; - stream->iotime = 0; + stream->iotime = time((time_t *) 0); /* as documented */; return (stream); }