Browse Source

Check for micro < 0, rather than checking "minor" twice.

Bug found with clang scan-build.  Fixes bug on f63e06d3dc6757d.
Bug not present in any released Tor.
Nick Mathewson 7 years ago
parent
commit
67cec7578c
1 changed files with 1 additions and 1 deletions
  1. 1 1
      src/or/routerparse.c

+ 1 - 1
src/or/routerparse.c

@@ -5551,7 +5551,7 @@ tor_version_parse_platform(const char *platform,
   if (strict) {
     if (router_version->major < 0 ||
         router_version->minor < 0 ||
-        router_version->minor < 0 ||
+        router_version->micro < 0 ||
         router_version->patchlevel < 0 ||
         router_version->svn_revision < 0) {
       return -1;