[Reconnoiter-devel] [reconnoiter commit] Reconnoiter branch, master, updated. 0d859ed7db2a6fbbfc378013a871419f0bd0c049

git at labs.omniti.com git at labs.omniti.com
Sun Nov 20 19:18:47 EST 2011


Pushed by: jesus
The branch, master has been updated
       via  0d859ed7db2a6fbbfc378013a871419f0bd0c049 (commit)
       via  24a62e58743f21a57603613305d0e3defdecb772 (commit)
       via  4e80e1fce8d410fe4154c5bfd4d2495288cd4747 (commit)
      from  899f2d2b74c6a8e1d8fc9a0ede60f226f83d551d (commit)

Summary of changes:
 src/noit_check.c |   16 ++++++++++------
 1 files changed, 10 insertions(+), 6 deletions(-)

Log:
commit 0d859ed7db2a6fbbfc378013a871419f0bd0c049
Merge: 899f2d2 24a62e5
Author: Theo Schlossnagle <jesus at omniti.com>
Date:   Sun Nov 20 19:18:42 2011 -0500

    Merge branch 'master' of github.com:omniti-labs/reconnoiter


commit 24a62e58743f21a57603613305d0e3defdecb772
Merge: c149f8a 4e80e1f
Author: Theo Schlossnagle <jesus at lethargy.org>
Date:   Sun Nov 20 16:18:26 2011 -0800

    Merge pull request #31 from rphillips/fixes/resolver_upstream
    
    fix the resolver but preserve the old functionality


commit 4e80e1fce8d410fe4154c5bfd4d2495288cd4747
Author: Ryan Phillips <ryan.phillips at rackspace.com>
Date:   Sun Nov 20 18:08:41 2011 -0600

    fix the resolver but preserve the old functionality

diff --git a/src/noit_check.c b/src/noit_check.c
index 2e744c9..e4baa67 100644
--- a/src/noit_check.c
+++ b/src/noit_check.c
@@ -587,12 +587,16 @@ noit_check_set_ip(noit_check_t *new_check,
 
   family = NOIT_CHECK_PREFER_V6(new_check) ? AF_INET6 : AF_INET;
   rv = inet_pton(family, ip_str, &a);
-  if(rv != 1 && !NOIT_CHECK_SINGLE_RESOLVE(new_check)) {
-    family = family == AF_INET ? AF_INET6 : AF_INET;
-    rv = inet_pton(family, ip_str, &a);
-    if(rv != 1) {
-      family = AF_INET;
-      memset(&a, 0, sizeof(a));
+  if(rv != 1) {
+    if (!NOIT_CHECK_SINGLE_RESOLVE(new_check)) {
+      family = family == AF_INET ? AF_INET6 : AF_INET;
+      rv = inet_pton(family, ip_str, &a);
+      if(rv != 1) {
+        family = AF_INET;
+        memset(&a, 0, sizeof(a));
+        failed = -1;
+      }
+    } else {
       failed = -1;
     }
   }




hooks/post-receive
-- 
Reconnoiter


More information about the Reconnoiter-devel mailing list