Browse Source

r11777@Kushana: nickm | 2007-01-01 21:01:10 -0500
Fix an idiot bug in r9181: snprintf returns <0 on error, not !=0.


svn:r9232

Nick Mathewson 17 years ago
parent
commit
6ae3ba9b2d
1 changed files with 1 additions and 1 deletions
  1. 1 1
      src/or/dirserv.c

+ 1 - 1
src/or/dirserv.c

@@ -1565,7 +1565,7 @@ generate_v2_networkstatus(void)
         const char *eos = find_whitespace(ri->platform+4);
         char *platform = tor_strndup(ri->platform+4, eos-(ri->platform+4));
         if (tor_snprintf(outp, endp-outp,
-                         "opt v %s\n", platform)) {
+                         "opt v %s\n", platform)<0) {
           log_warn(LD_BUG, "Unable to print router version.");
           goto done;
         }