[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[or-cvs] r13592: be more explicit about a harmless thing that freaked veracod (tor/trunk/src/or)



Author: arma
Date: 2008-02-19 17:32:32 -0500 (Tue, 19 Feb 2008)
New Revision: 13592

Modified:
   tor/trunk/src/or/dns.c
Log:
be more explicit about a harmless thing that freaked veracode out


Modified: tor/trunk/src/or/dns.c
===================================================================
--- tor/trunk/src/or/dns.c	2008-02-19 22:27:44 UTC (rev 13591)
+++ tor/trunk/src/or/dns.c	2008-02-19 22:32:32 UTC (rev 13592)
@@ -157,6 +157,7 @@
   if (!strcmpstart(msg, "Nameserver ") && (cp=strstr(msg, " has failed: "))) {
     char *ns = tor_strndup(msg+11, cp-(msg+11));
     const char *err = strchr(cp, ':'+2);
+    tor_assert(err);
     /* Don't warn about a single failed nameserver; we'll warn with 'all
      * nameservers have failed' if we're completely out of nameservers;
      * otherwise, the situation is tolerable. */