don't use the current directory to patch and build cmd/link
We were noticing sporadic `go test` failures where running an obfuscated binary could panic with: fatal error: invalid function symbol table It turns out that this could happen when modinfo.txtar runs first; when it patched the linker with `git -C apply`, its current directory had a valid git repository initialized, and apparently that somehow prevents the patches from being applied. It's unclear whether this is git's fault or our own, but in any case, using a temporary working directory is easier and fixes the bug. Do the same for `go build`, just in case.pull/674/head
parent
99d30c033e
commit
f7bde1d40e
Loading…
Reference in New Issue