Messages in this thread | | | Date | Sun, 1 Apr 2012 11:44:25 +0200 | From | Andi Kleen <> | Subject | Re: [PATCH] Extend core dump note section to contain file names of mapped files |
| |
On Sat, Mar 31, 2012 at 08:20:18PM -0700, H. Peter Anvin wrote: > On 03/31/2012 08:13 PM, Andi Kleen wrote: > >> I propose to save this information in core dump, as a new note > >> in note segment. > > > > Seems like a good idea but rather than write complicated code i would just reuse > > the /proc/*/maps code and dump it in that format? > > > > Does /proc/*/maps handle oddball characters in filenames?
It doesn't handle new lines well, but then if someone does that they break all programs that parse maps for other reasons (and likely a lot of other things too) anyways.
Other than that it should be ok: the file name is just the last component on the line.
-Andi -- ak@linux.intel.com -- Speaking for myself only.
| |