This is the mail archive of the
mailing list for the GDB project.
Re: [RFA/commit/procfs] /proc/.../map file descriptor leak
- From: Tom Tromey <tromey at redhat dot com>
- To: Joel Brobecker <brobecker at adacore dot com>
- Cc: gdb-patches at sourceware dot org
- Date: Wed, 09 Nov 2011 12:06:12 -0700
- Subject: Re: [RFA/commit/procfs] /proc/.../map file descriptor leak
- References: <email@example.com>
>>>>> "Joel" == Joel Brobecker <firstname.lastname@example.org> writes:
Joel> Digging further, I found that we leak the file descriptor created
Joel> when opening the procfs map file. we create a cleanup routine to make
Joel> sure that the associated file descriptor gets closed, but we never
Joel> call the cleanup.
This tickled a memory:
I didn't touch iterate_over_mappings though, so the old patch is
I think your patch is good. I agree it is cleaner the way you wrote it.