Patchwork Go patch committed: Implement new syscall package

login
register
mail settings
Submitter Ian Taylor
Date Oct. 31, 2011, 9:55 p.m.
Message ID <mcr4nyovnaq.fsf@dhcp-172-18-216-180.mtv.corp.google.com>
Download mbox | patch
Permalink /patch/122970/
State New
Headers show

Comments

Ian Taylor - Oct. 31, 2011, 9:55 p.m.
Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE> writes:

> /vol/gcc/src/hg/trunk/local/libgo/go/syscall/errstr_nor.go:22:8: error: referenc
> e to undefined name 'libc_strerror'
> make[4]: *** [syscall/syscall.lo] Error 1

Sorry about that.  I thought I had tested that, but evidently not.

Fixed like so.  Committed to mainline.

Ian

Patch

diff -r 56a1bd1d907a libgo/go/syscall/errstr_nor.go
--- a/libgo/go/syscall/errstr_nor.go	Mon Oct 31 14:41:55 2011 -0700
+++ b/libgo/go/syscall/errstr_nor.go	Mon Oct 31 14:53:22 2011 -0700
@@ -11,7 +11,7 @@ 
 	"unsafe"
 )
 
-//sysnb	strerror(errnum int) *byte
+//sysnb	strerror(errnum int) (buf *byte)
 //strerror(errnum int) *byte
 
 var errstr_lock sync.Mutex
@@ -19,7 +19,7 @@ 
 func Errstr(errno int) string {
 	errstr_lock.Lock()
 
-	bp := libc_strerror(errno)
+	bp := strerror(errno)
 	b := (*[1000]byte)(unsafe.Pointer(bp))
 	i := 0
 	for b[i] != 0 {