From: Michael Munday Date: Mon, 21 Mar 2016 17:30:50 +0000 (-0400) Subject: debug/gosym: accept PC quantum of 2 (for s390x) X-Git-Tag: go1.7beta1~747 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=921b2eba52906fc8b9bc4a8744dab63678f5ed3a;p=gostls13.git debug/gosym: accept PC quantum of 2 (for s390x) Needed for the header check to accept the header generated for s390x as Go 1.2 style rather than Go 1.1 style. Change-Id: I7b3713d4cc7514cfc58f947a45702348f6d7b824 Reviewed-on: https://go-review.googlesource.com/20966 Reviewed-by: Minux Ma --- diff --git a/src/debug/gosym/pclntab.go b/src/debug/gosym/pclntab.go index 01a9f11f05..291f102262 100644 --- a/src/debug/gosym/pclntab.go +++ b/src/debug/gosym/pclntab.go @@ -167,7 +167,7 @@ func (t *LineTable) go12Init() { // Check header: 4-byte magic, two zeros, pc quantum, pointer size. t.go12 = -1 // not Go 1.2 until proven otherwise if len(t.Data) < 16 || t.Data[4] != 0 || t.Data[5] != 0 || - (t.Data[6] != 1 && t.Data[6] != 4) || // pc quantum + (t.Data[6] != 1 && t.Data[6] != 2 && t.Data[6] != 4) || // pc quantum (t.Data[7] != 4 && t.Data[7] != 8) { // pointer size return }