]> Cypherpunks repositories - gostls13.git/commit
cmd/link: avoid crash on undefined func sym with external linking
authorThan McIntosh <thanm@google.com>
Thu, 26 Aug 2021 19:59:36 +0000 (15:59 -0400)
committerThan McIntosh <thanm@google.com>
Thu, 2 Sep 2021 14:44:50 +0000 (14:44 +0000)
commit014a9720f9526563ea5d9bff3d4d2d47b4e7752d
tree14609cdeadcc13495b33790a2ef648e43c99c922
parent37d4532867b9c49f936cb8e394dec44d8985fe29
cmd/link: avoid crash on undefined func sym with external linking

Fix a buglet in relocation processing that crops up with external
linking when you have an undefined function symbol that also has a
prototype (as if it were being defined in assembly src).

Fixes #47993.

Change-Id: Ib655492a63b205ffdc124cfd0cb7f7b731571821
Reviewed-on: https://go-review.googlesource.com/c/go/+/345473
Trust: Than McIntosh <thanm@google.com>
Run-TryBot: Than McIntosh <thanm@google.com>
Reviewed-by: Austin Clements <austin@google.com>
Reviewed-by: Cherry Mui <cherryyz@google.com>
Reviewed-by: Jeremy Faller <jeremy@golang.org>
src/cmd/go/testdata/script/link_external_undef.txt [new file with mode: 0644]
src/cmd/link/internal/ld/data.go