diff options
author | Ian Lance Taylor <ian@airs.com> | 2011-06-16 17:55:48 +0000 |
---|---|---|
committer | Ian Lance Taylor <ian@airs.com> | 2011-06-16 17:55:48 +0000 |
commit | 9d3b06987a9f8e6c40bf90f502f57d1c2b6b10ed (patch) | |
tree | 1e9fbd3e78c2294fcde27a50f3b09a6e358d8abb /gold/symtab.cc | |
parent | bcd823f19e31e93df9818913b1c1313175125bc9 (diff) | |
download | gdb-9d3b06987a9f8e6c40bf90f502f57d1c2b6b10ed.zip gdb-9d3b06987a9f8e6c40bf90f502f57d1c2b6b10ed.tar.gz gdb-9d3b06987a9f8e6c40bf90f502f57d1c2b6b10ed.tar.bz2 |
* symtab.cc (Warnings::issue_warning): Don't warn if relocation
occurs in same object.
Diffstat (limited to 'gold/symtab.cc')
-rw-r--r-- | gold/symtab.cc | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/gold/symtab.cc b/gold/symtab.cc index 92f83af..5d8c163 100644 --- a/gold/symtab.cc +++ b/gold/symtab.cc @@ -3282,6 +3282,12 @@ Warnings::issue_warning(const Symbol* sym, size_t relnum, off_t reloffset) const { gold_assert(sym->has_warning()); + + // We don't want to issue a warning for a relocation against the + // symbol in the same object file in which the symbol is defined. + if (sym->object() == relinfo->object) + return; + Warning_table::const_iterator p = this->warnings_.find(sym->name()); gold_assert(p != this->warnings_.end()); gold_warning_at_location(relinfo, relnum, reloffset, |