# HG changeset patch # User carl # Date 1142439711 28800 # Node ID ecd97e7eb1f0dd82a0ee980115f222e281b40c28 # Parent e8971c595845dce26063e220b0e90eef0549f21c properly return error code with reject reason diff -r e8971c595845 -r ecd97e7eb1f0 ChangeLog --- a/ChangeLog Mon Mar 13 08:45:54 2006 -0800 +++ b/ChangeLog Wed Mar 15 08:21:51 2006 -0800 @@ -1,5 +1,9 @@ $Id$ +5.15 2006-03-15 + bug fix - we failed to properly set the return code to indicate the + reason when rejecting mail for content filtering. + 5.14 2006-03-13 fix typo in the default config file and documentation for using multi.surbl.org diff -r e8971c595845 -r ecd97e7eb1f0 NEWS --- a/NEWS Mon Mar 13 08:45:54 2006 -0800 +++ b/NEWS Wed Mar 15 08:21:51 2006 -0800 @@ -1,5 +1,6 @@ $Id$ +5.15 2006-03-15 bug fix, failed to set reason code when rejecting mail from content filtering 5.14 2006-03-13 fix typo in default config and documentation for using multi.surbl.org 5.13 2006-03-12 patch from Jeff Evans to add SURBL/URIBL lookups 5.12 2006-01-08 use larger resolver buffer to accomodate spammers with many name servers diff -r e8971c595845 -r ecd97e7eb1f0 configure.in --- a/configure.in Mon Mar 13 08:45:54 2006 -0800 +++ b/configure.in Wed Mar 15 08:21:51 2006 -0800 @@ -1,7 +1,7 @@ AC_INIT(configure.in) AM_CONFIG_HEADER(config.h) -AM_INIT_AUTOMAKE(dnsbl,5.14) +AM_INIT_AUTOMAKE(dnsbl,5.15) AC_PATH_PROGS(BASH, bash) AC_LANG_CPLUSPLUS diff -r e8971c595845 -r ecd97e7eb1f0 src/dnsbl.cpp --- a/src/dnsbl.cpp Mon Mar 13 08:45:54 2006 -0800 +++ b/src/dnsbl.cpp Wed Mar 15 08:21:51 2006 -0800 @@ -995,12 +995,12 @@ } bool rejecting = alive.empty(); // if alive is empty, we must have set msg above in acceptable_content() if (!rejecting) { - char *msg; - if (check_hosts(priv, random, limit, msg, host, ip)) { + char *fmt; + if (check_hosts(priv, random, limit, fmt, host, ip)) { char adr[sizeof "255.255.255.255"]; adr[0] = '\0'; inet_ntop(AF_INET, (const u_char *)&ip, adr, sizeof(adr)); - snprintf(buf, sizeof(buf), msg, host, adr); + snprintf(buf, sizeof(buf), fmt, host, adr); msg = buf; rejecting = true; }