From nobody Tue Aug 27 07:25:45 2024 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WtJx61Jb2z5VFw5; Tue, 27 Aug 2024 07:25:46 +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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WtJx56fbBz4T8X; Tue, 27 Aug 2024 07:25:45 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1724743545; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=IeanAedIsS41P/kBQarn5fRw4t3K1pK7+RNW3qwAcNs=; b=qt3WlAyN3QEfOHjmJ2YCLS63coSwAwCPRS0nzKN44yKBdBvw/rjbzLk9VHss57Vfsn/GL6 /fumDZ+pisXRjBqbyObWQ7JfzcsVP9M22EKQSyyv/j7yzHnqenUaNlbIEcOzCpnjlIqzER 6gqOIuwK499ac2tAgB7ihGCdy+jwIUqpZCmX6RtXBIMOXo8ts/qjkOeKDt/4RjkdmVSQn+ V1lgXlEev4ZnW5+9y3mGftEIINVmBCIL5g0m8WP4E0LcYHXb8+fNqq3+QOqXhrvdfnvlAX V2JUeA4WfKr4dkIpV86geE0qYWluXnG+4yOoJGHmq+rRtsgNjtE3SE0abODf3A== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1724743545; a=rsa-sha256; cv=none; b=pv6t6UpkA8caevDgzFsggeV72brFuZttupsIkTIAWOFT4+8ORCqgdBSop19tnLg3o5kooD yYqce2NjMpttGXqOBGJ4HmYP6oH7Qy86W5aRUTqcIvPAQiJ94swlRsETsttxSjV7A2ke9W SVGbQfG4VeUv9fmRkHjbzczHEWLGQEs3SLms3XkT75+Xu79v+iPASnKRgtgY2x+D0RJI9S 06IoFue0omeGJeh6kbGh8y+fFAd9JmTE3DsiHHWUiCZhAh3eBRuvv1joMRedhS2U4f0H7U W4KdKZHGbfiN+eKm0BJtzVOyiS3cZXomhDp+vySeL/jwFfOyNtcOZ9yeJ9AZWg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1724743545; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=IeanAedIsS41P/kBQarn5fRw4t3K1pK7+RNW3qwAcNs=; b=uPYSyCtz5ki3EtqglwyadWH3IKueTCzgXIEHxsPfOBTyIOa1dUhd2pAJo39xneH64E0H7G Yuli3+DjP60kbFMfDVsa/5eDahzbBjKlOkDXnNmqBcJDkFUrraVQgsgfm1y2af/jAYG7wO JZGwKhE2lD2UjRV9BJNPfEFfpmgNKFh87LoPYw9l21rxJflZmxG+phWSMh82/4eJjNDAH/ pgMa2q9Z9Rs2MsHChgVLRcbkWDGm0LP4MCYuGtk+YPt/VLufZnv58EwVZJiAxTwZ+Wqla3 8I0vAkqWoyM0MxXA1BOcI0xAeXgw4UBwbwMXBIlV+HCSXudYNXJPg6AWhvcoNQ== 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 4WtJx56FyCzh7N; Tue, 27 Aug 2024 07:25:45 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 47R7PjqP006433; Tue, 27 Aug 2024 07:25:45 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 47R7PjWH006429; Tue, 27 Aug 2024 07:25:45 GMT (envelope-from git) Date: Tue, 27 Aug 2024 07:25:45 GMT Message-Id: <202408270725.47R7PjWH006429@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Stefan =?utf-8?Q?E=C3=9Fer?= Subject: git: ef5752762ba9 - main - contrib/bc: fix build with GCC List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: se X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: ef5752762ba9ec54d5c02023167d24bcdbb45fd7 Auto-Submitted: auto-generated The branch main has been updated by se: URL: https://cgit.FreeBSD.org/src/commit/?id=ef5752762ba9ec54d5c02023167d24bcdbb45fd7 commit ef5752762ba9ec54d5c02023167d24bcdbb45fd7 Author: Stefan Eßer AuthorDate: 2024-08-27 07:11:58 +0000 Commit: Stefan Eßer CommitDate: 2024-08-27 07:25:16 +0000 contrib/bc: fix build with GCC Building with GCC failed with the following error message: error: to be safe all intermediate pointers in cast from 'char **' to 'const char **' must be 'const' qualified [-Werror=cast-qual] This was caused by main() being declared with "char *argv[]" as the 3rd parameter, but argv later being passed cast to "const char**": 113 | if (BC_IS_BC) s = bc_main(argc, (const char**) argv); | ^ This is fixed by declaring the 3rd parameter of main() as "const char *argv[]". Reported by: CI MFC after: 3 days --- contrib/bc/src/main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/contrib/bc/src/main.c b/contrib/bc/src/main.c index e4a1f7399bb4..da4c27156029 100644 --- a/contrib/bc/src/main.c +++ b/contrib/bc/src/main.c @@ -54,7 +54,7 @@ #include int -main(int argc, char* argv[]) +main(int argc, const char* argv[]) { BcStatus s; char* name;