The code populating runtimeTypeToDIE was incorrectly adding StaticBase to the offset. We never noticed because on statically compiled executables StaticBase is always zero and on PIE and plugins the fallback code took care of the problem anyway. A change in Go 1.17 broke the fallback code, making the issue apparent. This commit fixes the setup of runtimeTypeToDIE and disables the fallback code for Go 1.17 and later. This change also fixes a rare failure in TestPluginVariables when PIE is enabled. |
||
|---|---|---|
| .. | ||
| astutil | ||
| config | ||
| dwarf | ||
| elfwriter | ||
| gobuild | ||
| goversion | ||
| locspec | ||
| logflags | ||
| proc | ||
| terminal | ||
| version | ||