projects
/
binutils-gdb.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
gas: NEWS: Add the RISC-V features for 2.39
[binutils-gdb.git]
/
gold
/
reloc.cc
diff --git
a/gold/reloc.cc
b/gold/reloc.cc
index 34a836f4e6fcce4468c926a6ee652a47466fd418..9cab05264171d23c2a155ca4a867546b23875a02 100644
(file)
--- a/
gold/reloc.cc
+++ b/
gold/reloc.cc
@@
-1,6
+1,6
@@
// reloc.cc -- relocate input files for gold.
// reloc.cc -- relocate input files for gold.
-// Copyright (C) 2006-202
1
Free Software Foundation, Inc.
+// Copyright (C) 2006-202
2
Free Software Foundation, Inc.
// Written by Ian Lance Taylor <iant@google.com>.
// This file is part of gold.
// Written by Ian Lance Taylor <iant@google.com>.
// This file is part of gold.
@@
-1602,7
+1602,10
@@
Track_relocs<size, big_endian>::advance(off_t offset)
elfcpp::Rel<size, big_endian> rel(this->prelocs_ + this->pos_);
if (static_cast<off_t>(rel.get_r_offset()) >= offset)
break;
elfcpp::Rel<size, big_endian> rel(this->prelocs_ + this->pos_);
if (static_cast<off_t>(rel.get_r_offset()) >= offset)
break;
- ++ret;
+ // Skip R_*_NONE relocation entries with r_sym of zero
+ // without counting.
+ if (rel.get_r_info() != 0)
+ ++ret;
this->pos_ += this->reloc_size_;
}
return ret;
this->pos_ += this->reloc_size_;
}
return ret;