summaryrefslogtreecommitdiff
path: root/gdb/objfiles.c
diff options
context:
space:
mode:
authorMark Kettenis <kettenis@gnu.org>2003-10-29 18:29:07 +0000
committerMark Kettenis <kettenis@gnu.org>2003-10-29 18:29:07 +0000
commit4a2bba68033924d6e7ae9f599cd263d9e3522a5f (patch)
tree30cf87ef5a3d61ebe507eacfdb507bfee5d7426e /gdb/objfiles.c
parent59f85e95c379a8ad205278d690e4ebe08b084510 (diff)
downloadgdb-4a2bba68033924d6e7ae9f599cd263d9e3522a5f.tar.gz
* objfiles.h (clear_objfile_data): New prototype.
* objfiles.c (clear_objfile_data): New function. * symfile.c (reread_symbols): Clear per-objfile data.
Diffstat (limited to 'gdb/objfiles.c')
-rw-r--r--gdb/objfiles.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/gdb/objfiles.c b/gdb/objfiles.c
index 1321b828fff..9a181f4f33b 100644
--- a/gdb/objfiles.c
+++ b/gdb/objfiles.c
@@ -1166,6 +1166,13 @@ objfile_free_data (struct objfile *objfile)
}
void
+clear_objfile_data (struct objfile *objfile)
+{
+ gdb_assert (objfile->data != NULL);
+ memset (objfile->data, 0, objfile->num_data * sizeof (void *));
+}
+
+void
set_objfile_data (struct objfile *objfile, const struct objfile_data *data,
void *value)
{