They are reportedly generated by llvm-mingw clang21.
For #75219
Fixes #75221
Change-Id: I7fa7e13039bc7eee826cc19826985ca0e357a9ff
Reviewed-on: https://go-review.googlesource.com/c/go/+/700137
Reviewed-by: Cherry Mui <cherryyz@google.com>
Reviewed-by: Michael Pratt <mpratt@google.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Quim Muntal <quimmuntal@gmail.com>
Auto-Submit: Ian Lance Taylor <iant@golang.org>
(cherry picked from commit
ea00650784bc2909580c7decf729f668349aa939)
Reviewed-on: https://go-review.googlesource.com/c/go/+/708356
// isSymNameOffset checks symbol name if it is encoded as offset into string table.
func isSymNameOffset(name [8]byte) (bool, uint32) {
if name[0] == 0 && name[1] == 0 && name[2] == 0 && name[3] == 0 {
- return true, binary.LittleEndian.Uint32(name[4:])
+ offset := binary.LittleEndian.Uint32(name[4:])
+ if offset == 0 {
+ // symbol has no name
+ return false, 0
+ }
+ return true, offset
}
return false, 0
}