runtime: error error 3221226356 (C0000374) in CGO module in Windows #39127
Labels
compiler/runtime
Issues related to the Go compiler and/or runtime.
FrozenDueToAge
NeedsInvestigation
Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
OS-Windows
WaitingForInfo
Issue is not actionable because of missing required information, which needs to be provided.
Milestone
The CGO module gorfc provides GO bindings to pre-compiled SAP NWRFC SDK binaries. The module works fine on Linux and macOS and never worked quite stable on Windows. Currently, it occasionally terminates on Windows, with heap corruption error 3221226356 (hex C0000374).
I am not sure if the toolchain and compiler flags are maybe part of the problem, here further details.
Toolchain
SAP NWRFC SDK binaries require Microsoft C Runtime DLLs version 12.0 and our Windows toolchain is based on MinGW64, with following settings:
The TDM GCC is not used because this issue still occurs: error adding symbols: File in wrong format
Is this the optimal toolchain for building CGO modules on Windows, or another approach could be considered?
Compiler flags
Compiler flags recommended for SAP NWRFC SDK bindings on Windows platform, are given for Windows native compiler and linker:
GCC counterparts are currently missing for some of them, commented in gorfc source)
Any help/ideas on toolchain, flags, possible root causes and troubleshooting approach, would be of a great help.
Here the details about GO environment on Windows.
The text was updated successfully, but these errors were encountered: