aboutsummaryrefslogtreecommitdiff
path: root/src/pkg/debug
diff options
context:
space:
mode:
authorJoel Sing <jsing@google.com>2012-11-15 03:36:19 +1100
committerJoel Sing <jsing@google.com>2012-11-15 03:36:19 +1100
commit8c96e6d7404f27f473f97dcef8b9fc1f7f7161da (patch)
tree38034d142d94130bce970e45a32c17184cd5da12 /src/pkg/debug
parent76689845e331d32c94d77280c34fb92e7dde79ba (diff)
downloadgo-8c96e6d7404f27f473f97dcef8b9fc1f7f7161da.tar.xz
debug/elf: fix offset for GNU version symbols
Since we no longer skip the first entry when reading a symbol table, we no longer need to allow for the offset difference when processing the GNU version symbols. Unbreaks builds on Linux. R=golang-dev, agl, iant CC=golang-dev https://golang.org/cl/6843057
Diffstat (limited to 'src/pkg/debug')
-rw-r--r--src/pkg/debug/elf/file.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/pkg/debug/elf/file.go b/src/pkg/debug/elf/file.go
index 25b04d7959..b030b043df 100644
--- a/src/pkg/debug/elf/file.go
+++ b/src/pkg/debug/elf/file.go
@@ -700,8 +700,8 @@ func (f *File) gnuVersionInit(str []byte) {
// gnuVersion adds Library and Version information to sym,
// which came from offset i of the symbol table.
func (f *File) gnuVersion(i int, sym *ImportedSymbol) {
- // Each entry is two bytes; skip undef entry at beginning.
- i = (i + 1) * 2
+ // Each entry is two bytes.
+ i = i * 2
if i >= len(f.gnuVersym) {
return
}