aboutsummaryrefslogtreecommitdiffstats
path: root/cshared/remote_cshared.go
diff options
context:
space:
mode:
authorVadim Markovtsev <vadim@sourced.tech>2016-06-21 17:14:53 +0300
committerVadim Markovtsev <vadim@sourced.tech>2016-06-21 17:14:53 +0300
commitda07dca4523ebd25c634152a62cae4a72eb5783f (patch)
tree028122b562ce464ae4410525b5b3d3dfcea4846c /cshared/remote_cshared.go
parentbea415417e87fbb403095e8cd3fb8512a1a97af8 (diff)
downloadgo-git-da07dca4523ebd25c634152a62cae4a72eb5783f.tar.gz
Wrap more objects with CGo
Diffstat (limited to 'cshared/remote_cshared.go')
-rw-r--r--cshared/remote_cshared.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/cshared/remote_cshared.go b/cshared/remote_cshared.go
index 04a26de..9ae72f3 100644
--- a/cshared/remote_cshared.go
+++ b/cshared/remote_cshared.go
@@ -130,7 +130,7 @@ func c_Remote_Head(r uint64) (*C.char, int, *C.char) {
if err != nil {
return nil, ErrorCodeInternal, C.CString(err.Error())
}
- return C.CString(string(hash[:])), ErrorCodeSuccess, nil
+ return CBytes(hash[:]), ErrorCodeSuccess, nil
}
//export c_Remote_Fetch
@@ -177,7 +177,7 @@ func c_Remote_Ref(r uint64, refName string) (*C.char, int, *C.char) {
if err != nil {
return nil, ErrorCodeInternal, C.CString(err.Error())
}
- return C.CString(string(hash[:])), ErrorCodeSuccess, nil
+ return CBytes(hash[:]), ErrorCodeSuccess, nil
}
//export c_Remote_Refs