mirror of
https://github.com/Zenithsiz/ftmemsim-valgrind.git
synced 2026-02-04 02:18:37 +00:00
Add patch from Stephan Kulow to solve the following:
read_procselfmaps calls *record_mapping which
is startup_segment_callback for init_memory. But this
again calls through read_symbols read_procselfmaps
again with read_from_file == True. But this overwrites
the internal buffer and causes parsing errors.
(What makes the error a bit funny is that valgrind
wouldn't have catched that error afaik :)
Anyway: our solution is to forbid read_from_file from
with callbacks
MERGE TO STABLE
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@1820
This commit is contained in:
parent
c0f0059bf7
commit
76b167b551
@ -133,9 +133,12 @@ void VG_(read_procselfmaps) (
|
||||
UInt foffset;
|
||||
UChar rr, ww, xx, pp, ch, tmp;
|
||||
|
||||
if (read_from_file) {
|
||||
static Int depth = 0;
|
||||
|
||||
if (read_from_file && depth == 0) {
|
||||
VG_(read_procselfmaps_contents)();
|
||||
}
|
||||
depth++;
|
||||
|
||||
if (0)
|
||||
VG_(message)(Vg_DebugMsg, "raw:\n%s", procmap_buf );
|
||||
@ -215,6 +218,7 @@ void VG_(read_procselfmaps) (
|
||||
|
||||
i = i_eol + 1;
|
||||
}
|
||||
depth--;
|
||||
}
|
||||
|
||||
/*--------------------------------------------------------------------*/
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user