aboutsummaryrefslogtreecommitdiff
path: root/gdb
diff options
context:
space:
mode:
authorTom Tromey <tom@tromey.com>2019-03-01 19:56:45 -0700
committerTom Tromey <tom@tromey.com>2019-03-15 16:02:08 -0600
commit788c80d1aff685e66b8105ddc7451cfa6a03bf1d (patch)
tree0c73a75e7c45512daa54e02d7671882ef85ccc0c /gdb
parent1b7a07cba0aa096c2eb66895ef339aa5143e9995 (diff)
downloadgdb-788c80d1aff685e66b8105ddc7451cfa6a03bf1d.zip
gdb-788c80d1aff685e66b8105ddc7451cfa6a03bf1d.tar.gz
gdb-788c80d1aff685e66b8105ddc7451cfa6a03bf1d.tar.bz2
Remove some unneeded initializations in minimal_symbol_reader
minimal_symbol_reader::record_full does not need to initialize any minsym fields to 0, because that was already done implicitly via the use of XCNEW when allocating the msym_bunch. gdb/ChangeLog 2019-03-15 Tom Tromey <tom@tromey.com> * minsyms.c (minimal_symbol_reader::record_full): Remove some initializations.
Diffstat (limited to 'gdb')
-rw-r--r--gdb/ChangeLog5
-rw-r--r--gdb/minsyms.c10
2 files changed, 5 insertions, 10 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index 867df17..ceedf53 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,5 +1,10 @@
2019-03-15 Tom Tromey <tom@tromey.com>
+ * minsyms.c (minimal_symbol_reader::record_full): Remove some
+ initializations.
+
+2019-03-15 Tom Tromey <tom@tromey.com>
+
* objfiles.h (struct objfile_per_bfd_storage)
<demangled_hash_languages>: Now a bitset.
* minsyms.c (add_minsym_to_demangled_hash_table): Update.
diff --git a/gdb/minsyms.c b/gdb/minsyms.c
index cbb45f1..bc6e536 100644
--- a/gdb/minsyms.c
+++ b/gdb/minsyms.c
@@ -1163,16 +1163,6 @@ minimal_symbol_reader::record_full (const char *name, int name_len,
MSYMBOL_SECTION (msymbol) = section;
MSYMBOL_TYPE (msymbol) = ms_type;
- MSYMBOL_TARGET_FLAG_1 (msymbol) = 0;
- MSYMBOL_TARGET_FLAG_2 (msymbol) = 0;
- /* Do not use the SET_MSYMBOL_SIZE macro to initialize the size,
- as it would also set the has_size flag. */
- msymbol->size = 0;
-
- /* The hash pointers must be cleared! If they're not,
- add_minsym_to_hash_table will NOT add this msymbol to the hash table. */
- msymbol->hash_next = NULL;
- msymbol->demangled_hash_next = NULL;
/* If we already read minimal symbols for this objfile, then don't
ever allocate a new one. */