您的路径可能需要NUL终止:
import ( "golang.org/x/sys/windows")var ( lib = windows.MustLoadDLL("dllname.dll") init = lib.MustFindProc("Init"))func main() { path := "some" bytePath = []byte(path + "x00") init.Call( uintptr(unsafe.Pointer(&bytePath[0])), uintptr(9) )}


