From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 2116) id 4AC573858C66; Mon, 23 Oct 2023 21:03:47 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 4AC573858C66 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1698095027; bh=r8WVh7YH6mUe2m1u3X/3atR4vuADVKecnb/3rI5t2jM=; h=From:To:Subject:Date:From; b=bh3NRUx6vrjU+7tsV1C10+DlYBQzDNMHKiidqfbi3h+7QFOeFdcBr5hRoiXY5TfrR L1dQsSP9rgq6xLkFs6ANtD3hpUwx7MwLlRqFRXgZqC4jMHo3P1UCJgWuMp/L9Qkr0E n3+6VUGBK+OwWCdv7296ViauSl9zkZEI6kzRMnBM= MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="utf-8" From: Ian Lance Taylor To: gcc-cvs@gcc.gnu.org Subject: [gcc r14-4869] syscall: add missing type conversion X-Act-Checkin: gcc X-Git-Author: Ian Lance Taylor X-Git-Refname: refs/heads/master X-Git-Oldrev: 32b74c9e1d46932a4bbb1f46353bfc43c702c20a X-Git-Newrev: 2621bd1bac614b63e52d0deb4ab2ff287a9fafa8 Message-Id: <20231023210347.4AC573858C66@sourceware.org> Date: Mon, 23 Oct 2023 21:03:47 +0000 (GMT) List-Id: https://gcc.gnu.org/g:2621bd1bac614b63e52d0deb4ab2ff287a9fafa8 commit r14-4869-g2621bd1bac614b63e52d0deb4ab2ff287a9fafa8 Author: Ian Lance Taylor Date: Thu Oct 19 16:46:14 2023 -0700 syscall: add missing type conversion The gofrontend incorrectly accepted code that was missing a type conversion. The test case for this is bug518.go in https://go.dev/cl/536537. Future CLs in this series will detect the type error. Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/536638 Diff: --- gcc/go/gofrontend/MERGE | 2 +- libgo/go/syscall/errstr.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/gcc/go/gofrontend/MERGE b/gcc/go/gofrontend/MERGE index 398d2671b64d..0f961157dfd1 100644 --- a/gcc/go/gofrontend/MERGE +++ b/gcc/go/gofrontend/MERGE @@ -1,4 +1,4 @@ -c201fa2a684ada551ca9a0825a3075a0a69498de +081ec9824a74ec9d82628d8d2f6b9a7a4c35a529 The first line of this file holds the git revision number of the last merge done from the gofrontend repository. diff --git a/libgo/go/syscall/errstr.go b/libgo/go/syscall/errstr.go index 9f688e2a0c7b..02f228adc59d 100644 --- a/libgo/go/syscall/errstr.go +++ b/libgo/go/syscall/errstr.go @@ -24,7 +24,7 @@ func Errstr(errnum int) string { } return string(b[:i]) } - if errno != ERANGE { + if Errno(errno) != ERANGE { return "strerror_r failure" } }