From: Michael Hudson-Doyle Date: Fri, 8 Apr 2016 02:27:35 +0000 (+1200) Subject: cmd/cgo: fix cgo with gccgo X-Git-Tag: go1.7beta1~809 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=092ef8a2ca60e1a7573442757b02ec1efc456c2c;p=gostls13.git cmd/cgo: fix cgo with gccgo Change-Id: I1780899255e22c16d7f8e9947609a1c284d7c42e Reviewed-on: https://go-review.googlesource.com/21690 Reviewed-by: David Crawshaw Run-TryBot: Michael Hudson-Doyle TryBot-Result: Gobot Gobot --- diff --git a/src/cmd/cgo/out.go b/src/cmd/cgo/out.go index 621c41c6b2..88b0147364 100644 --- a/src/cmd/cgo/out.go +++ b/src/cmd/cgo/out.go @@ -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; }