after writing the first header.
svn path=/branches/BRANCH_6-3/; revision=5071
* Do not crash with a null pointer dereference when opening the BSMTP file
fails. Improve error checking and reporting. Reported by Reto Schüttel,
Debian Bug#416625. Fix based on a patch by Nico Golde.
+* Make BSMTP output actually work, it would persistently fail with SOCKET error
+ after writing the first header.
# DOCUMENTATION:
* Extend --mda documentation, discourage use of qmail-inject.
n = 0;
if (ctl->mda || ctl->bsmtp) {
- n = fwrite(buf, last - buf, 1, sinkfp);
+ n = fwrite(buf, 1, last - buf, sinkfp);
if (ferror(sinkfp)) n = -1;
} else if (ctl->smtp_socket != -1)
n = SockWrite(ctl->smtp_socket, buf, last - buf);