andelf / go-curl

golang curl(libcurl) binding.
Apache License 2.0
485 stars 131 forks source link

Go 1.6 compatibility #43

Closed ottob closed 8 years ago

ottob commented 8 years ago

https://tip.golang.org/doc/go1.6#cgo

$ go version
go version go1.6rc2 darwin/amd64
$ go test
--- FAIL: TestVersionInfo (0.00s)
    core_test.go:20: protocol should be in [dict file ftp ftps gopher http https imap imaps ldap ldaps pop3 pop3s rtmp rtsp smtp smtps telnet tftp scp sftp] and is smb.
    core_test.go:20: protocol should be in [dict file ftp ftps gopher http https imap imaps ldap ldaps pop3 pop3s rtmp rtsp smtp smtps telnet tftp scp sftp] and is smbs.

--- FAIL: TestCallbackFunction (0.00s)
panic: runtime error: cgo argument has Go pointer to Go pointer [recovered]
    panic: runtime error: cgo argument has Go pointer to Go pointer

goroutine 19 [running]:
testing.tRunner.func1(0xc8200fa000)
    /usr/local/go/src/testing/testing.go:467 +0x192
github.com/andelf/go-curl._cgoCheckPointer0(0x42ece00, 0xc8200da0e0, 0x0, 0x0, 0x0, 0x6000000)
    ??:0 +0x4d
github.com/andelf/go-curl.(*CURL).Setopt(0xc8200da0e0, 0x4e2b, 0x4343140, 0xc8200d01e0, 0x0, 0x0)
    /Users/ottob/go/src/github.com/andelf/go-curl/easy.go:197 +0x10e7
github.com/andelf/go-curl.TestCallbackFunction(0xc8200fa000)
    /Users/ottob/go/src/github.com/andelf/go-curl/easy_test.go:45 +0x1a7
testing.tRunner(0xc8200fa000, 0x45ca0b0)
    /usr/local/go/src/testing/testing.go:473 +0x98
created by testing.RunTests
    /usr/local/go/src/testing/testing.go:582 +0x892
exit status 2
FAIL    github.com/andelf/go-curl   0.019s