Plug memory leak in update-cache.c
Hi,
Might not be that an big an issue as it should be freed on exit, but might cause problems with big trees.
----
Plug memory leak in update-cache.c.
update-cache.c: 22f3ccd47db4f0888901109a8cbf883d272d1cba
update-cache.c +1 -0
@@ -202,6 +202,7 @@printf ("%s: needs update\n" , ce->name);continue ; } +free (active_cache[i]); active_cache[i] = new; } }
Signature · 1 line
Martin Schlemmer
update-cache.c: 22f3ccd47db4f0888901109a8cbf883d272d1cba
update-cache.c +1 -0
@@ -202,6 +202,7 @@printf ("%s: needs update\n" , ce->name);continue ; } +free (active_cache[i]); active_cache[i] = new; } }
Dear diary, on Thu, Apr 14, 2005 at 10:53:50AM CEST, I got a letter where Martin Schlemmer <[email protected]> told me that...
Quoted 15 lines
Hi,
Might not be that an big an issue as it should be freed on exit, but might cause problems with big trees.
----
Plug memory leak in
update-cache.c.Signed-off-by Martin Schlemmer <[email protected]>
update-cache.c:22f3ccd47db4f0888901109a8cbf883d272d1cba
update-cache.c line 208
Quoted 7 lines
update-cache.c +1
-0@@ -202,6 +202,7 @@printf ("%s: needs update\n" , ce->name);continue ; } +free (active_cache[i]); active_cache[i] = new; } }
FYI, new could've contained active_cache[i] at that time, so you needed to check for that. Fixed though, thanks for pointing it out.
Signature · 3 lines
Petr "Pasky" Baudis Stuff: http://pasky.or.cz/ C++: an octopus made by nailing extra legs onto a dog. -- Steve Taylor
Quoted 13 lines · Petr Baudis
Dear diary, on Thu, Apr 14, 2005 at 10:53:50AM CEST, I got a letter where Martin Schlemmer <[email protected]> told me that...
Quoted 11 lines
Hi,
Might not be that an big an issue as it should be freed on exit, but might cause problems with big trees.
----
Plug memory leak in
update-cache.c.Signed-off-by Martin Schlemmer <[email protected]>
Quoted 15 lines
update-cache.c line 208
Quoted 11 lines
update-cache.c:22f3ccd47db4f0888901109a8cbf883d272d1cbaupdate-cache.c +1
-0@@ -202,6 +202,7 @@printf ("%s: needs update\n" , ce->name);continue ; } +free (active_cache[i]); active_cache[i] = new; } }FYI, new could've contained active_cache[i] at that time, so you needed to check for that. Fixed though, thanks for pointing it out.
Urk, no, please drop. As Ingo pointed out, the memory was obtained via mmap ...
Signature · 1 line
Martin Schlemmer
Dear diary, on Sat, Apr 16, 2005 at 02:00:21AM CEST, I got a letter where Martin Schlemmer <[email protected]> told me that...
Quoted 30 lines · Petr Baudis
Quoted 13 lines
Dear diary, on Thu, Apr 14, 2005 at 10:53:50AM CEST, I got a letter where Martin Schlemmer <[email protected]> told me that...
Quoted 11 lines
Hi,
Might not be that an big an issue as it should be freed on exit, but might cause problems with big trees.
----
Plug memory leak in
update-cache.c.Signed-off-by Martin Schlemmer <[email protected]>Quoted 15 lines
update-cache.c line 208
Quoted 11 lines
update-cache.c:22f3ccd47db4f0888901109a8cbf883d272d1cbaupdate-cache.c +1
-0@@ -202,6 +202,7 @@printf ("%s: needs update\n" , ce->name);continue ; } +free (active_cache[i]); active_cache[i] = new; } }FYI, new could've contained active_cache[i] at that time, so you needed to check for that. Fixed though, thanks for pointing it out.
Quoted 2 lines
Urk, no, please drop. As Ingo pointed out, the memory was obtained via mmap ...
Yes, I've just noticed that. ;-)
Signature · 3 lines
Petr "Pasky" Baudis Stuff: http://pasky.or.cz/ C++: an octopus made by nailing extra legs onto a dog. -- Steve Taylor