Originally I was investigating a specific reproducible memory leak so I stuck valgrind on GDB and fixed 3 or 4 leaks which show up clearly once you iterate 1000s of command via the MI protocol interface. Version: 6.8.50.20090509-cvs
Created attachment 3928 [details] Patch for the memory leaks and a overlapping memcpy() Patch for the memory leaks and a overlapping memcpy() case valgrind found.
Thanks for the patch. The thing to do is send the patch plus a ChangeLog entry to the gdb-patches list. Also, if you do not have copyright assignment paperwork in place, we will need that. You can contact me off-list and I will get you started, if you are willing.
We've fixed a ton of leaks and I think this patch must also be long since obsolete.