Browse Source

Fix bug in r8440: base32 uses 5 bytes per char, not 4.

svn:r8447
Nick Mathewson 18 years ago
parent
commit
58200f06a5
1 changed files with 1 additions and 1 deletions
  1. 1 1
      src/or/dns.c

+ 1 - 1
src/or/dns.c

@@ -1606,7 +1606,7 @@ static void
 launch_wildcard_check(int len, const char *suffix)
 {
   char random_bytes[16], name[64], *addr;
-  size_t n = (len+1)/2;
+  size_t n = (len*5+7)/8;
   int r;
 
   tor_assert(n <= sizeof(random_bytes));