summaryrefslogtreecommitdiff
path: root/regress/lib
diff options
context:
space:
mode:
authorJoel Sing <jsing@cvs.openbsd.org>2014-09-28 13:57:17 +0000
committerJoel Sing <jsing@cvs.openbsd.org>2014-09-28 13:57:17 +0000
commitb4596ba9c54fa56cadbe23746bda65f1bc97e6b8 (patch)
treee360244fd01aac6f786b2cd2722ea838f6aee892 /regress/lib
parentf0e9838b79a760e1d6cfcc439451c05f5e902fd6 (diff)
Make the goressl regress test compile again.
Diffstat (limited to 'regress/lib')
-rw-r--r--regress/lib/libressl/goressl/ressl.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/regress/lib/libressl/goressl/ressl.go b/regress/lib/libressl/goressl/ressl.go
index 32508618845..17f457d1bfe 100644
--- a/regress/lib/libressl/goressl/ressl.go
+++ b/regress/lib/libressl/goressl/ressl.go
@@ -126,7 +126,7 @@ func (r *Ressl) Connect(host, port string) error {
// Read reads data the SSL connection into the given buffer.
func (r *Ressl) Read(buf []byte) (int, error) {
var inlen C.size_t
- if C.ressl_read(r.ctx, (*C.char)(unsafe.Pointer(&buf[0])), C.size_t(len(buf)), (*C.size_t)(unsafe.Pointer(&inlen))) != 0 {
+ if C.ressl_read(r.ctx, unsafe.Pointer(&buf[0]), C.size_t(len(buf)), (*C.size_t)(unsafe.Pointer(&inlen))) != 0 {
return -1, fmt.Errorf("read failed: %v", r.Error())
}
return int(inlen), nil
@@ -137,7 +137,7 @@ func (r *Ressl) Write(buf []byte) (int, error) {
var outlen C.size_t
p := C.CString(string(buf))
defer C.free(unsafe.Pointer(p))
- if C.ressl_write(r.ctx, p, C.size_t(len(buf)), (*C.size_t)(unsafe.Pointer(&outlen))) != 0 {
+ if C.ressl_write(r.ctx, unsafe.Pointer(p), C.size_t(len(buf)), (*C.size_t)(unsafe.Pointer(&outlen))) != 0 {
return -1, fmt.Errorf("write failed: %v", r.Error())
}
return int(outlen), nil