projects
/
exim.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Memory management: when running under the testsuite, check every string variable...
[exim.git]
/
src
/
src
/
spam.c
diff --git
a/src/src/spam.c
b/src/src/spam.c
index 8898c591e7ec3336cb3f8b9e6040af2571a67426..ac25a881fb7679db1a425f8485bf5898bdaa0086 100644
(file)
--- a/
src/src/spam.c
+++ b/
src/src/spam.c
@@
-2,8
+2,10
@@
* Exim - an Internet mail transport agent *
*************************************************/
* Exim - an Internet mail transport agent *
*************************************************/
-/* Copyright (c) Tom Kistner <tom@duncanthrax.net> 2003 - 2015 */
-/* License: GPL */
+/* Copyright (c) Tom Kistner <tom@duncanthrax.net> 2003 - 2015
+ * License: GPL
+ * Copyright (c) The Exim Maintainers 2016
+ */
/* Code for calling spamassassin's spamd. Called from acl.c. */
/* Code for calling spamassassin's spamd. Called from acl.c. */
@@
-412,12
+414,12
@@
if (wrote == -1)
}
/* now send the file */
}
/* now send the file */
-/* spamd sometimes accepts conections but doesn't read data off
+/* spamd sometimes accepts con
n
ections but doesn't read data off
* the connection. We make the file descriptor non-blocking so
* that the write will only write sufficient data without blocking
* the connection. We make the file descriptor non-blocking so
* that the write will only write sufficient data without blocking
- * and we poll the desciptor to make sure that we can write without
+ * and we poll the desc
r
iptor to make sure that we can write without
* blocking. Short writes are gracefully handled and if the whole
* blocking. Short writes are gracefully handled and if the whole
- * trasaction takes too long it is aborted.
+ * tra
n
saction takes too long it is aborted.
* Note: poll() is not supported in OSX 10.2 and is reported to be
* broken in more recent versions (up to 10.4).
*/
* Note: poll() is not supported in OSX 10.2 and is reported to be
* broken in more recent versions (up to 10.4).
*/
@@
-492,7
+494,8
@@
if (ferror(mbox_file))
(void)fclose(mbox_file);
/* we're done sending, close socket for writing */
(void)fclose(mbox_file);
/* we're done sending, close socket for writing */
-shutdown(spamd_sock,SHUT_WR);
+if (!sd->is_rspamd)
+ shutdown(spamd_sock,SHUT_WR);
/* read spamd response using what's left of the timeout. */
memset(spamd_buffer, 0, sizeof(spamd_buffer));
/* read spamd response using what's left of the timeout. */
memset(spamd_buffer, 0, sizeof(spamd_buffer));