Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(388)

Issue 119630043: code review 119630043: cmd/link: fix zig-zag decoding (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
10 years, 9 months ago by mdempsky
Modified:
10 years, 9 months ago
Reviewers:
rsc
CC:
golang-codereviews, minux, rsc
Visibility:
Public.

Description

cmd/link: fix zig-zag decoding The >>1 shift needs to happen before converting to int32, otherwise large values will decode with an incorrect sign bit. The <<31 shift can happen before or after, but before is consistent with liblink and the go12symtab doc. Bug demo at http://play.golang.org/p/jLrhPUakIu

Patch Set 1 #

Patch Set 2 : diff -r f483391c3008 https://code.google.com/p/go #

Patch Set 3 : diff -r f483391c3008 https://code.google.com/p/go #

Unified diffs Side-by-side diffs Delta from patch set Stats (+1 line, -1 line) Patch
M src/cmd/link/pclntab.go View 1 chunk +1 line, -1 line 0 comments Download

Messages

Total messages: 4
mdempsky
Hello golang-codereviews@googlegroups.com, I'd like you to review this change to https://code.google.com/p/go
10 years, 9 months ago (2014-08-09 00:00:32 UTC) #1
minux
test?
10 years, 9 months ago (2014-08-09 00:35:26 UTC) #2
rsc
LGTM I have some tests for this pending, although it's unlikely we'd get to a ...
10 years, 9 months ago (2014-08-11 17:51:08 UTC) #3
rsc
10 years, 9 months ago (2014-08-11 18:14:40 UTC) #4
*** Submitted as https://code.google.com/p/go/source/detail?r=62969513e59e ***

cmd/link: fix zig-zag decoding

The >>1 shift needs to happen before converting to int32, otherwise
large values will decode with an incorrect sign bit.

The <<31 shift can happen before or after, but before is consistent
with liblink and the go12symtab doc.

Bug demo at http://play.golang.org/p/jLrhPUakIu

LGTM=rsc
R=golang-codereviews, minux, rsc
CC=golang-codereviews
https://codereview.appspot.com/119630043

Committer: Russ Cox <rsc@golang.org>
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b