[RFA] bug fixes for varobj.c
Martin M. Hunt
hunt@redhat.com
Mon Jun 10 23:09:00 GMT 2002
Anything using varobj is randomly corrupting memory and will cause crashes in
Insight or anything using mi varobjs. This patch fixes that and some other
minor problems.
--
Martin Hunt
GDB Engineer
Red Hat, Inc.
2002-06-10 Martin M. Hunt <hunt@redhat.com>
* varobj.c (struct varobj_root): Change frame from CORE_ADDR to
struct frame_id.
(varobj_create): Store frame_id for root.
(varobj_gen_name): Use xasprintf.
(varobj_update): Save and restore frame using get_frame_id() and
frame_find_by_id().
(create_child): Use xasprintf.
(new_root_variable): Initialize frame_id.
(c_name_of_child): Use xasprintf. Call find_frame_by_id().
(c_value_of_variable): Use xasprintf. Move mem_fileopen call
to prevent memory leak.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: v
Type: text/x-diff
Size: 8034 bytes
Desc: not available
URL: <http://sourceware.org/pipermail/gdb-patches/attachments/20020610/d00a4113/attachment.bin>
More information about the Gdb-patches
mailing list