aboutsummaryrefslogtreecommitdiff
path: root/gas/symbols.c
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2008-08-22 06:07:45 +0000
committerAlan Modra <amodra@gmail.com>2008-08-22 06:07:45 +0000
commit73e24c6845aa23ed023402152501009ed1dcc62f (patch)
tree35a99a835bb2bf12e5fb2b547c71331236c68df0 /gas/symbols.c
parent4e3b43ed44934795eb36ee4bc5f5d6d26da851ec (diff)
downloadgdb-73e24c6845aa23ed023402152501009ed1dcc62f.zip
gdb-73e24c6845aa23ed023402152501009ed1dcc62f.tar.gz
gdb-73e24c6845aa23ed023402152501009ed1dcc62f.tar.bz2
* symbols.c (symbol_clone): Ensure clones are not external.
Diffstat (limited to 'gas/symbols.c')
-rw-r--r--gas/symbols.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/gas/symbols.c b/gas/symbols.c
index 3020710..84f394c 100644
--- a/gas/symbols.c
+++ b/gas/symbols.c
@@ -596,13 +596,20 @@ symbol_clone (symbolS *orgsymP, int replace)
symbol_lastP = newsymP;
else if (orgsymP->sy_next)
orgsymP->sy_next->sy_previous = newsymP;
+
+ /* Symbols that won't be output can't be external. */
+ S_CLEAR_EXTERNAL (orgsymP);
orgsymP->sy_previous = orgsymP->sy_next = orgsymP;
debug_verify_symchain (symbol_rootP, symbol_lastP);
symbol_table_insert (newsymP);
}
else
- newsymP->sy_previous = newsymP->sy_next = newsymP;
+ {
+ /* Symbols that won't be output can't be external. */
+ S_CLEAR_EXTERNAL (newsymP);
+ newsymP->sy_previous = newsymP->sy_next = newsymP;
+ }
return newsymP;
}