From owner-dev-commits-src-all@freebsd.org Mon Sep 6 14:42:49 2021 Return-Path: Delivered-To: dev-commits-src-all@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 1B6E66760B6; Mon, 6 Sep 2021 14:42:49 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4H3B2c6zH2z3pdv; Mon, 6 Sep 2021 14:42:48 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id D017020853; Mon, 6 Sep 2021 14:42:48 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 186EgmD5073032; Mon, 6 Sep 2021 14:42:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 186Egm1Q073031; Mon, 6 Sep 2021 14:42:48 GMT (envelope-from git) Date: Mon, 6 Sep 2021 14:42:48 GMT Message-Id: <202109061442.186Egm1Q073031@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Edward Tomasz Napierala Subject: git: efe014e6b177 - main - iconv: Make it possible to build iconv(3) test suite. MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: trasz X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: efe014e6b177ba1b0d70f7df751f5066d4eafe9b Auto-Submitted: auto-generated X-BeenThere: dev-commits-src-all@freebsd.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Commit messages for all branches of the src repository List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 06 Sep 2021 14:42:49 -0000 The branch main has been updated by trasz: URL: https://cgit.FreeBSD.org/src/commit/?id=efe014e6b177ba1b0d70f7df751f5066d4eafe9b commit efe014e6b177ba1b0d70f7df751f5066d4eafe9b Author: Edward Tomasz Napierala AuthorDate: 2021-09-06 14:41:06 +0000 Commit: Edward Tomasz Napierala CommitDate: 2021-09-06 14:41:26 +0000 iconv: Make it possible to build iconv(3) test suite. It was broken after 1243a98e38a5. Reviewed By: allanjude Sponsored by: Klara, Inc. Differential Revision: https://reviews.freebsd.org/D31816 --- tools/test/iconv/gnu/gnu.c | 16 ++++++++-------- tools/test/iconv/posix/posix.c | 16 ++++++++-------- tools/test/iconv/tablegen/tablegen.c | 4 ++-- 3 files changed, 18 insertions(+), 18 deletions(-) diff --git a/tools/test/iconv/gnu/gnu.c b/tools/test/iconv/gnu/gnu.c index 47e83ec3ae3d..ecf180d23b98 100644 --- a/tools/test/iconv/gnu/gnu.c +++ b/tools/test/iconv/gnu/gnu.c @@ -243,8 +243,8 @@ ctl_uc_hook(void) struct iconv_hooks hooks; iconv_t cd; size_t inbytesleft = 15, outbytesleft = 40; - const char **inptr; - const char *s = "Hello World!"; + char **inptr; + char *s = "Hello World!"; char **outptr; char *outbuf; @@ -273,8 +273,8 @@ ctl_wc_hook(void) struct iconv_hooks hooks; iconv_t cd; size_t inbytesleft, outbytesleft = 40; - const char **inptr; - const char *s = "Hello World!"; + char **inptr; + char *s = "Hello World!"; char **outptr; char *outbuf; @@ -350,7 +350,7 @@ ctl_mb_to_uc_fb(void) size_t inbytesleft, outbytesleft; uint16_t inbuf[1] = { 0xF187 }; uint8_t outbuf[4] = { 0x00, 0x00, 0x00, 0x00 }; - const char *inptr; + char *inptr; char *outptr; int ret; @@ -366,7 +366,7 @@ ctl_mb_to_uc_fb(void) if (iconvctl(cd, ICONV_SET_FALLBACKS, (void *)&fb) != 0) return (1); - inptr = (const char *)inbuf; + inptr = (char *)inbuf; outptr = (char *)outbuf; inbytesleft = 2; outbytesleft = 4; @@ -389,7 +389,7 @@ gnu_openinto(void) { iconv_allocation_t *myspace; size_t inbytesleft, outbytesleft; - const char *inptr; + char *inptr; char *inbuf = "works!", *outptr; char outbuf[6]; @@ -398,7 +398,7 @@ gnu_openinto(void) if (iconv_open_into("ASCII", "ASCII", myspace) == -1) return (1); - inptr = (const char *)inbuf; + inptr = (char *)inbuf; outptr = (char *)outbuf; inbytesleft = 6; outbytesleft = 6; diff --git a/tools/test/iconv/posix/posix.c b/tools/test/iconv/posix/posix.c index 2502393b5509..7faed92416a3 100644 --- a/tools/test/iconv/posix/posix.c +++ b/tools/test/iconv/posix/posix.c @@ -108,7 +108,7 @@ conv_ret(void) { iconv_t cd; size_t inbytesleft, outbytesleft; - const char *inptr; + char *inptr; char *outptr; uint32_t outbuf[4]; uint32_t inbuf[2] = { 0x00000151, 0x00000171 }; @@ -116,7 +116,7 @@ conv_ret(void) if ((cd = iconv_open("ASCII", "UTF-32LE")) == (iconv_t)-1) return (1); - inptr = (const char *)inbuf; + inptr = (char *)inbuf; outptr = (char *)outbuf; inbytesleft = 8; outbytesleft = 16; @@ -129,7 +129,7 @@ conv_2big(void) { iconv_t cd; size_t inbytesleft, outbytesleft; - const char *inptr; + char *inptr; char *outptr; uint32_t inbuf[4]; uint32_t outbuf[2]; @@ -138,7 +138,7 @@ conv_2big(void) if ((cd = iconv_open("ASCII", "ASCII")) == (iconv_t)-1) return (1); - inptr = (const char *)inbuf; + inptr = (char *)inbuf; outptr = (char *)outbuf; inbytesleft = 16; outbytesleft = 8; @@ -168,7 +168,7 @@ conv_einval(void) { iconv_t cd; size_t inbytesleft, outbytesleft; - const char *inptr; + char *inptr; char *outptr; uint32_t outbuf[4]; uint16_t inbuf[1] = { 0xEA42 }; @@ -177,7 +177,7 @@ conv_einval(void) if ((cd = iconv_open("UTF-32", "BIG5")) == (iconv_t)-1) return (1); - inptr = (const char *)inbuf; + inptr = (char *)inbuf; outptr = (char *)outbuf; inbytesleft = 2; outbytesleft = 16; @@ -207,7 +207,7 @@ conv_eilseq(void) { iconv_t cd; size_t inbytesleft, outbytesleft; - const char *inptr; + char *inptr; char *outptr; uint32_t outbuf[4]; uint16_t inbuf[1] = { 0x8AC0 }; @@ -216,7 +216,7 @@ conv_eilseq(void) if ((cd = iconv_open("Latin2", "UTF-16LE")) == (iconv_t)-1) return (1); - inptr = (const char *)inbuf; + inptr = (char *)inbuf; outptr = (char *)outbuf; inbytesleft = 4; outbytesleft = 16; diff --git a/tools/test/iconv/tablegen/tablegen.c b/tools/test/iconv/tablegen/tablegen.c index ee8cecad70d8..a67de54ff310 100644 --- a/tools/test/iconv/tablegen/tablegen.c +++ b/tools/test/iconv/tablegen/tablegen.c @@ -287,7 +287,7 @@ do_conv(iconv_t cd, bool uniinput) { size_t inbytesleft, outbytesleft, ret; uint32_t outbuf; uint32_t inbuf; - const char *inbuf_; + char *inbuf_; char *outbuf_; for (inbuf = 0; inbuf < (lflag ? 0x100000 : 0x10000); inbuf += 1) { @@ -297,7 +297,7 @@ do_conv(iconv_t cd, bool uniinput) { outbytesleft = 4; outbuf = 0x00000000; outbuf_ = (char *)&outbuf; - inbuf_ = (const char *)&inbuf; + inbuf_ = (char *)&inbuf; iconv(cd, NULL, NULL, NULL, NULL); fb_flags = 0; errno = 0;