check for external-ip before forking
authorChristian Grothoff <christian@grothoff.org>
Thu, 15 Sep 2011 12:54:56 +0000 (12:54 +0000)
committerChristian Grothoff <christian@grothoff.org>
Thu, 15 Sep 2011 12:54:56 +0000 (12:54 +0000)
src/nat/nat_mini.c

index ccdc832658d406228eb8245f8ea2cca56c2f0b3a..8014a451d916fd91b9d1c863184b12c7b5d50fa4 100644 (file)
@@ -163,6 +163,9 @@ GNUNET_NAT_mini_get_external_ipv4 (struct GNUNET_TIME_Relative timeout,
 {
   struct GNUNET_NAT_ExternalHandle *eh;
 
+  if (GNUNET_SYSERR ==
+      GNUNET_OS_check_helper_binary ("external-ip"))
+    return NULL;
   eh = GNUNET_malloc (sizeof (struct GNUNET_NAT_ExternalHandle));
   eh->cb = cb;
   eh->cb_cls = cb_cls;