[or-cvs] r11863: bugfix on r11301: Fix a minor memory leak whenever we wrote (in tor/trunk: . src/common)

arma at seul.org arma at seul.org
Thu Oct 11 03:10:52 UTC 2007


Author: arma
Date: 2007-10-10 23:10:52 -0400 (Wed, 10 Oct 2007)
New Revision: 11863

Modified:
   tor/trunk/ChangeLog
   tor/trunk/src/common/util.c
Log:
bugfix on r11301:
Fix a minor memory leak whenever we wrote out a file. Bugfix on
0.2.0.7-alpha.


Modified: tor/trunk/ChangeLog
===================================================================
--- tor/trunk/ChangeLog	2007-10-11 02:03:53 UTC (rev 11862)
+++ tor/trunk/ChangeLog	2007-10-11 03:10:52 UTC (rev 11863)
@@ -93,6 +93,8 @@
       Bugfix in 0.2.0.7-alpha.
     - Fix a minor memory leak whenever we parse guards from our state
       file. Bugfix on 0.2.0.7-alpha.
+    - Fix a minor memory leak whenever we wrote out a file. Bugfix on
+      0.2.0.7-alpha.
 
   o Code simplifications and refactoring:
     - Make a bunch of functions static.  Remove some dead code.

Modified: tor/trunk/src/common/util.c
===================================================================
--- tor/trunk/src/common/util.c	2007-10-11 02:03:53 UTC (rev 11862)
+++ tor/trunk/src/common/util.c	2007-10-11 03:10:52 UTC (rev 11863)
@@ -1657,8 +1657,6 @@
     }
   }
 
-  memset(file_data, 0, sizeof(file_data));
-  file_data->fd = -1;
   tor_free(file_data->filename);
   tor_free(file_data->tempname);
   tor_free(file_data);



More information about the tor-commits mailing list