(1) Typo in redirect router; (2) Update version number; (3) Update
[exim.git] / src / src / verify.c
index 0c1d6b0ebe3b0b56c987ce93f82db02e41affa3f..b3712c4062381d335fac0ceb8ea1cbac8d6c2041 100644 (file)
@@ -1,10 +1,10 @@
-/* $Cambridge: exim/src/src/verify.c,v 1.7 2004/11/22 11:30:04 ph10 Exp $ */
+/* $Cambridge: exim/src/src/verify.c,v 1.9 2005/01/04 10:00:42 ph10 Exp $ */
 
 /*************************************************
 *     Exim - an Internet mail transport agent    *
 *************************************************/
 
-/* Copyright (c) University of Cambridge 1995 - 2004 */
+/* Copyright (c) University of Cambridge 1995 - 2005 */
 /* See the file NOTICE for conditions of use and distribution. */
 
 /* Functions concerned with verifying things. The original code for callout
@@ -2593,6 +2593,7 @@ while ((domain = string_nextinlist(&list, &sep, buffer, sizeof(buffer))) != NULL
   else
     {
     int keysep = 0;
+    BOOL defer = FALSE; 
     uschar *keydomain; 
     uschar keybuffer[256];
   
@@ -2625,11 +2626,17 @@ while ((domain = string_nextinlist(&list, &sep, buffer, sizeof(buffer))) != NULL
         dnslist_domain = string_copy(domain);
         HDEBUG(D_dnsbl) debug_printf("=> that means %s is listed at %s\n", 
           keydomain, domain);
+        return OK;   
         }
          
-      if (rc != FAIL) return rc;   /* OK or DEFER */
+      /* If the lookup deferred, remember this fact. We keep trying the rest
+      of the list to see if we get a useful result, and if we don't, we return
+      DEFER at the end. */
 
+      if (rc == DEFER) defer = TRUE;
       }    /* continue with next keystring domain/address */
+
+    if (defer) return DEFER;
     }  
   }        /* continue with next dnsdb outer domain */