aboutsummaryrefslogtreecommitdiffstats
path: root/sink.c
Commit message (Collapse)AuthorAgeFilesLines
* Fix verbose mode progress formatting regression from 6.3.10.Matthias Andree2010-02-261-0/+4
|
* BSMTP error reporting and stdout handling fixesMatthias Andree2010-02-261-22/+24
| | | | | * Do not close stdout when using mda and "bsmtp -" at the same time. * Log operating system errors when BSMTP writes fail.
* Refactoring: Rename smtp_open() to smtp_setup()Matthias Andree2010-02-101-2/+2
|
* Declare Sunil's new smtp_rset() function static.Matthias Andree2010-01-281-1/+1
| | | | | | | There is currently no user outside the compilation unit, so there is no need to have it visible. svn path=/branches/BRANCH_6-3/; revision=5464
* Recover from SMTP protocol errors on RSET. (Sunil Shetye)Matthias Andree2010-01-281-8/+19
| | | | | | | | | | | | | Apply patch from Sunil Shetye to fix a problem reported by James Moe. Before this fix, fetchmail's SMTP client would not recover from errors such as lost connections that were encountered when fetchmail had sent RSET, for instance, after an anti-spam filter dropped the connection after detecting spam. Fetchmail then tried to send subsequent mail through this broken connection and deferred retrieval until the next poll. Now, if RSET fails, fetchmail closes the connection and reopens it for the next message to be delivered. svn path=/branches/BRANCH_6-3/; revision=5463
* Always treat 530 SMTP codes as temporary.Matthias Andree2009-05-251-0/+12
| | | | | | | These are usually configuration errors (missing TLS/SSL). Patch partially taken from Petr Cerny, Novell's Bugzilla 246829. svn path=/branches/BRANCH_6-3/; revision=5339
* Enforce minimum recommended SMTP timeouts, apply to EHLO/LHLO as well.Matthias Andree2009-05-251-5/+5
| | | | | | | | | | | | | | | | | | | | Short timeouts could cause fetchmail to not wait long enough for the "250 Ok" after shipping a long message, particularly with synchronous mailers and extensive spam filtering. This caused fetchmail to re-fetch long messages. While the actual fix is making sure that the timeout is no shorter than the time the SMTP server takes to process the message, we now enforce the minimum RFC-5321 recommended timeouts even if the user configures a lower timeout. This is to fix Berlios Bug #10972, reported by Viktor Binzberger. NOTE: it is untested whether we will properly delete the message from the POP3/IMAP server or mark it as seen, as the upstream server may close the connection sooner. svn path=/branches/BRANCH_6-3/; revision=5338
* Fix compiler warning (unused parameter).Matthias Andree2009-05-251-0/+2
| | | | svn path=/branches/BRANCH_6-3/; revision=5333
* Fix bounce message detail regression from 6.3.0.Matthias Andree2009-05-251-3/+7
| | | | | | | | Non-delivery messages now mention the original reason for the bounce message again. It was lost in merging Holger Mauermann's patch before 6.3.0, and caused a sink.c compiler warning ever since. svn path=/branches/BRANCH_6-3/; revision=5332
* Fix compiler warning. Patch by Prasad J. Pandit, pj.pandit)a(yahoo.co.in.Matthias Andree2009-05-251-1/+1
| | | | svn path=/branches/BRANCH_6-3/; revision=5331
* Fix a few compiler warnings around implicit conversion or extra ";".Matthias Andree2009-01-141-1/+1
| | | | svn path=/branches/BRANCH_6-3/; revision=5261
* Fix long-standing (since r2215/v4.6.8) crash on NULL pointer dereferenceMatthias Andree2007-07-291-1/+1
| | | | | | | when the local SMTP listener rejects a warning message of fetchmail's. Report and suggested fix by Earl Chew. svn path=/branches/BRANCH_6-3/; revision=5119
* Make BSMTP output actually work, it would persistently fail with SOCKET error Matthias Andree2007-03-291-1/+1
| | | | | | 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 Matthias Andree2007-03-291-2/+8
| | | | | | | fails. Improve error checking and reporting. Reported by Reto Schttel, Debian Bug#416625. Fix based on a patch by Nico Golde. svn path=/branches/BRANCH_6-3/; revision=5070
* Back out --smtp list from bouncing. Sunil reports that this may require AUTH ↵Matthias Andree2007-02-241-31/+3
| | | | | | or other precautions, as it's relaying to the outside. svn path=/branches/BRANCH_6-3/; revision=5042
* Try --smtp list when bouncing. Reported by Christian Kurz, Debian Bug #150137.Matthias Andree2007-02-211-3/+31
| | | | svn path=/branches/BRANCH_6-3/; revision=5041
* Remove excess no-op strcpy() after strdup() found by Andreas Krennmair.Matthias Andree2006-12-121-1/+0
| | | | svn path=/branches/BRANCH_6-3/; revision=4989
* Fix regression from 6.3.4 that crashes fetchmail --mda FOO when encounteringMatthias Andree2006-11-141-5/+5
| | | | | | | malformed message. Report by Neil Hoggart (also closes BerliOS bugs #9364, #9412, #9449). svn path=/branches/BRANCH_6-3/; revision=4940
* Freeaddrinfo() fix for Uli Zappe's bug.Matthias Andree2006-08-071-3/+3
| | | | | | This might fix Debian Bug#294547 and Bug#377135. svn path=/branches/BRANCH_6-3/; revision=4880
* Improve sink error detection and reporting.Matthias Andree2006-08-061-14/+28
| | | | svn path=/branches/BRANCH_6-3/; revision=4878
* set no bouncemail now also prevents 'General SMTP/ESMTP error.' bounces.Matthias Andree2006-04-041-1/+2
| | | | svn path=/branches/BRANCH_6-3/; revision=4780
* More warning fixes (from FreeBSD 6.1).Matthias Andree2006-03-251-1/+1
| | | | svn path=/branches/BRANCH_6-3/; revision=4753
* Further cleanups to compile with C++ compiler.Matthias Andree2006-03-151-2/+2
| | | | svn path=/branches/BRANCH_6-3/; revision=4744
* Fix more compiler warnings.Matthias Andree2006-03-141-1/+2
| | | | svn path=/branches/BRANCH_6-3/; revision=4736
* Yet another bogus free() to be fixed.Matthias Andree2006-01-191-1/+1
| | | | svn path=/branches/BRANCH_6-3/; revision=4655
* Fix segfault or bus error after bouncing a message. This bug was Matthias Andree2006-01-191-2/+7
| | | | | | | introduced into 6.3.0 when removing alloca(); it caused fetchmail to free random memory. Reported by Nathaniel W. Turner, Debian Bug#348747. svn path=/branches/BRANCH_6-3/; revision=4652
* * SMTP/LMTP cleanup to fix these two bugs:Matthias Andree2005-12-201-40/+41
| | | | | | | | | - switch back to SMTP after having tried LMTP hosts (multiple smtphost hosts) - switch back to LMTP after sending a bounce. The patch removes the global state variable that was the root of this problem. Patch by Sunil Shetye. svn path=/branches/BRANCH_6-3/; revision=4581
* Do not trash destination domain if multiple messages are forwarded into theMatthias Andree2005-12-131-32/+31
| | | | | | same SMTP/LMTP connection. Reported by Joachim Feise, Berlios Bug #5849. svn path=/branches/BRANCH_6-3/; revision=4547
* Sunil Shetye fixed these problems in a patch posted to fetchmail-devel:Matthias Andree2005-11-141-56/+43
| | | | | | | | | | | | | | | | | | | | | | | | | 1. parsed_host is not freed in some cases. This happens when the first smtp server is down in this setup: poll mailserver ... smtphost "smtpserver1" "smtpserver2" ... 2. parsed_host is being initialized for UNIX socket also. For UNIX socket, parsed_host should be NULL. 3. If EHLO fails on a UNIX socket, it tries HELO on a network socket! 4. ctl->destaddr is allocated memory in two cases. This memory is never freed. 5. ctl->destaddr was being assigned in a very convoluted manner. Since, parsed_host is already set correctly now, it can be used directly. svn path=/trunk/; revision=4443
* Use new host_fqdn() interface.Matthias Andree2005-10-301-1/+4
| | | | svn path=/trunk/; revision=4382
* Rearrange #include directives in an attempt to fix BerliOS Bug #4725,Matthias Andree2005-09-191-2/+2
| | | | | | Darwin 7.9 build fails in resource.h with ru_utime/ru_stime incomplete types. svn path=/trunk/; revision=4296
* Write RFC-compliant BSMTP envelopes. Reported by Nico Golde.Matthias Andree2005-08-161-3/+8
| | | | svn path=/trunk/; revision=4237
* Remove port/service dualism and make everything a service.Matthias Andree2005-08-021-8/+0
| | | | svn path=/trunk/; revision=4219
* Get rid of alloca() in fetchmail.Matthias Andree2005-07-311-33/+46
| | | | svn path=/trunk/; revision=4209
* INCOMPATIBLE: DROP --netsec/-T option, NET_SECURITY macro - the required ↵Matthias Andree2005-07-301-3/+3
| | | | | | library is no longer available. svn path=/trunk/; revision=4192
* strcpy -> strlcpy, strcat -> strlcatMatthias Andree2005-07-301-7/+8
| | | | | | Add a few comments. svn path=/trunk/; revision=4187
* Add From: header to warning emails. Debian Bug#244828.Matthias Andree2005-07-231-0/+2
| | | | svn path=/trunk/; revision=4169
* Really fix Debian bug #207919 (junk in Received: header when smtphost set).Matthias Andree2005-07-201-2/+1
| | | | | | | The 6.2.5 NEWS file hat errantly stated Gregan's patch had fixed Debian bug #207919 when it had fixed #212484 (workaround dbmail length overflow) instead. svn path=/trunk/; revision=4129
* Nalin Dahyabhai's fix for sink.c/transact.c to reserve sufficient Matthias Andree2005-07-031-1/+1
| | | | | | | space for \r\n trailers in snprintf calls. Sent by Miloslav Trmac, possibly fixing Red Hat bug #114470. svn path=/trunk/; revision=4071
* Cesar Eduardo Barros's fix to avoid double @ when username has @ and envelopeMatthias Andree2005-06-291-1/+5
| | | | | | sender is null. Debian bug #272289. svn path=/trunk/; revision=4061
* Fix typo, LSMTP -> LMTP.Matthias Andree2005-04-241-1/+1
| | | | svn path=/trunk/; revision=4032
* Misc. sprintf and pid_t fixes.Matthias Andree2004-11-101-2/+2
| | | | svn path=/trunk/; revision=4000
* Clean up the horrible HAVE_[V]SNPRINTF mess, use Trio on systems that lackMatthias Andree2004-11-101-52/+7
| | | | | | real snprintf or vsnprintf. svn path=/trunk/; revision=3996
* Use iana_charset rather than calling nl_langinfo(CODESET).Matthias Andree2004-11-071-1/+1
| | | | svn path=/trunk/; revision=3981
* Let stuff_warning do the RFC-2047 encoding.Matthias Andree2004-10-201-9/+13
| | | | | | Change stuff_warning interface to take a rfc2047 charset info parameter. svn path=/trunk/; revision=3968
* Fix miscellaneous warnings.Matthias Andree2004-10-201-0/+1
| | | | svn path=/trunk/; revision=3953
* Add MIME headers to specify body encoding for mail warnings.Matthias Andree2004-10-141-1/+6
| | | | svn path=/trunk/; revision=3943
* Merge Holger Mauermann's bounce patch, 2003-10-23-6.2.5-mauermann-bounce.diffMatthias Andree2004-10-121-10/+33
| | | | | | | | | | | | | | | | | | | Holger Mauermann writes: The attached patch for fetchmail-6.2.5 sends IMHO much better bounce messages. Changes: - The SMTP command "MAIL FROM: FETCHMAIL-DAEMON@..." is changed to "MAIL FROM: <>" as required by RFC 2821 - Removed Return-path: header, as required by RFC 2821 - Changed From:, added Subject: header - changed the human readable part to be more descriptive and detailed svn path=/trunk/; revision=3939
* Remove space after "MAIL FROM:" (patch from Phil Endecott)Rob Funk2004-07-211-1/+1
| | | | svn path=/trunk/; revision=3925
* Cast arguments of is*() ctype.h functions to unsigned char to be 8-bit safe.Matthias Andree2004-06-191-4/+4
| | | | svn path=/trunk/; revision=3903