]> git.ipfire.org Git - thirdparty/tor.git/commitdiff
fix an impossible-to-actually-trigger overflow in descriptor generation
authorRoger Dingledine <arma@torproject.org>
Fri, 15 Jan 2010 20:55:08 +0000 (15:55 -0500)
committerRoger Dingledine <arma@torproject.org>
Fri, 15 Jan 2010 20:56:54 +0000 (15:56 -0500)
src/or/rephist.c

index 7f71dc0fba0f1cc903387bfe493eac2635629e8d..e606db3b7b2e0eff2987ed3b26050579ac864d01 100644 (file)
@@ -1613,7 +1613,7 @@ rep_hist_get_bandwidth_lines(int for_extrainfo)
   size_t len;
 
   /* opt (read|write)-history yyyy-mm-dd HH:MM:SS (n s) n,n,n,n,n... */
-  len = (60+20*NUM_TOTALS)*2;
+  len = (60+21*NUM_TOTALS)*2;
   buf = tor_malloc_zero(len);
   cp = buf;
   for (r=0;r<2;++r) {