runtime: export cgoCheck functions
The functions cgoCheckPointer and cgoCheckResult are called by code generated by cgo. That means that we need to export them using go:linkname, as otherwise they are local symbols. The cgo code currently uses weak references to only call the symbols if they are defined, which is why it has been working--the cgo code has not been doing any checks. Reviewed-on: https://go-review.googlesource.com/80295 From-SVN: r255347
This commit is contained in:
parent
9638589faf
commit
79c9f76563
2 changed files with 5 additions and 1 deletions
|
@ -1,4 +1,4 @@
|
|||
1949a203fca0c8bde6f2690ebc36427c5e3953c7
|
||||
338f7434175bb71f3c8905e9ad7f480aec3afee6
|
||||
|
||||
The first line of this file holds the git revision number of the last
|
||||
merge done from the gofrontend repository.
|
||||
|
|
|
@ -11,6 +11,10 @@ import (
|
|||
"unsafe"
|
||||
)
|
||||
|
||||
// Functions called by cgo-generated code.
|
||||
//go:linkname cgoCheckPointer runtime.cgoCheckPointer
|
||||
//go:linkname cgoCheckResult runtime.cgoCheckResult
|
||||
|
||||
// Pointer checking for cgo code.
|
||||
|
||||
// We want to detect all cases where a program that does not use
|
||||
|
|
Loading…
Add table
Reference in a new issue