1
0
mirror of https://github.com/golang/go synced 2024-10-01 08:38:47 -06:00

cmd/cgo: fix cgo with gccgo

Change-Id: I1780899255e22c16d7f8e9947609a1c284d7c42e
Reviewed-on: https://go-review.googlesource.com/21690
Reviewed-by: David Crawshaw <crawshaw@golang.org>
Run-TryBot: Michael Hudson-Doyle <michael.hudson@canonical.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
This commit is contained in:
Michael Hudson-Doyle 2016-04-08 14:27:35 +12:00
parent c3b3e7b4ef
commit 092ef8a2ca

View File

@ -1451,7 +1451,7 @@ const char *_cgoPREFIX_Cfunc_CString(struct __go_string s) {
void *_cgoPREFIX_Cfunc_CBytes(struct __go_open_array b) {
char *p = malloc(b.__count);
memmove(p, b.__data, b.__count);
memmove(p, b.__values, b.__count);
return p;
}