mirror of
https://github.com/bminor/binutils-gdb.git
synced 2025-12-26 01:07:52 +00:00
* objfiles.c (struct objfile_data): Delete member cleanup and replace
with save, free. (register_objfile_data_with_cleanup): Delete arg cleanup and replace with save, free. All callers updated. (clear_objfile_data): Replace cleanup loop with separate save and free loops. * objfiles.h (register_objfile_data_with_cleanup): Update. * arm-tdep.c (arm_objfile_data_free): Renamed from arm_objfile_data_cleanup, all callers updated. * dwarf2read.c (dwarf2_per_objfile_free): Renamed from dwarf2_per_objfile_cleanup, all callers updated. * python/py-objfile.c (py_free_objfile): Renamed from clean_up_objfile, all callers updated. * python/py-type.c (save_objfile_types): Renamed from clean_up_objfile_types, all callers updated.
This commit is contained in:
@@ -500,9 +500,18 @@ extern int in_plt_section (CORE_ADDR, char *);
|
||||
/* Keep a registry of per-objfile data-pointers required by other GDB
|
||||
modules. */
|
||||
|
||||
/* Allocate an entry in the per-objfile registry. */
|
||||
extern const struct objfile_data *register_objfile_data (void);
|
||||
|
||||
/* Allocate an entry in the per-objfile registry.
|
||||
SAVE and FREE are called when clearing objfile data.
|
||||
First all registered SAVE functions are called.
|
||||
Then all registered FREE functions are called.
|
||||
Either or both of SAVE, FREE may be NULL. */
|
||||
extern const struct objfile_data *register_objfile_data_with_cleanup
|
||||
(void (*cleanup) (struct objfile *, void *));
|
||||
(void (*save) (struct objfile *, void *),
|
||||
void (*free) (struct objfile *, void *));
|
||||
|
||||
extern void clear_objfile_data (struct objfile *objfile);
|
||||
extern void set_objfile_data (struct objfile *objfile,
|
||||
const struct objfile_data *data, void *value);
|
||||
|
||||
Reference in New Issue
Block a user