From nobody Tue May 28 04:42:10 2024 X-Original-To: dev-commits-src-all@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 4VpKcL4kGdz5LZ2Q; Tue, 28 May 2024 04:42:10 +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 4VpKcL4Hg2z4cH4; Tue, 28 May 2024 04:42:10 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1716871330; 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=OUPapiRxCYezTbrSe+UI4HtGB5TSCzVsRgr1s3jss/M=; b=e6eUnmi1wUvPqwWoodRJVorG+zWNjGJCCpFkzT/dVo5AMyqXVFaA2YuBEkRCPuqf76uEKG 9e7A6n5rieLhajUxQ7sXkjdlskRV0ktuJPvDox4HeOgqmOLi18RQP4y1jbhWdrfxs/Ag6A dZJJUEyJzrJsd6OOIOvSCWl9YOUxiDmr9Mffnwwl+8WL8YqVokRBmG3oM2OAF8twDZ0VjX O5Amr5KnRcMYQiJ19pIbsQpGksfBEX/Cg4KXFAyeJOXUd555aptEbjKcGsvpewtV+FRRcg aRsA/aj5nuRzqpxiCe2wpLjVWKEY/LFSJHllO7YlwGkUOLM+yMpBxtQ7uWYsyA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1716871330; a=rsa-sha256; cv=none; b=tabZKG7Ggfns3PPpn9ANv5MflVmD2pYUyVDsshcSQvz4oo1ca9FJO5RJBAlu/6wqD4oB5/ 8FeUyW7j3NkAjqdS2bIrl/MTSXtPnbXsOuyE98G3ObNuDGhh146Wl4s7LmwFMxczX4c94v P/encJrlpTfq5aX197RLCA//kyt0kMIPsvx9DduwBxoBZzINdF3SZrjl48vimff4ou+iw0 rv1AbNId0NI4YXYuXPYJhQg+OYEk0e4oDovYA8hFy3PUiTcnd0r8cd2YKCaJ9KlByPn8dR 4d7i9+NFfm4xfdnPeRFGxr3TlFsdVAPz0Vf1S2J+DodjR4+DT5hzXGHzc/umRQ== 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=1716871330; 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=OUPapiRxCYezTbrSe+UI4HtGB5TSCzVsRgr1s3jss/M=; b=D9wvoNSg8PaopSb/ZL/mx//5G/CNK5ph5DnJCKujjaHNPJABpW61XA1Tv/BqcvoH/a5bAN 1jgFbRNBbC8saxh53qwD2TozppwhEy54Zqmq9vGdmWPEGBRKyztB/xBz7OA5q8bseeas65 K+hQcv9fQjIZBvLCgVddtHbxXWqGuG7T/oXvLTCxLkwPIV0zq67a4r9tK7imi2ZMgnCcCA GYBwvdMvZrW2udP/92DCSWHNeNeyyQX2puX7LKcm4w3eUhMnZFAJykbuFtKhNTGAL2uxOD zJ7ZrIS1LsTxqKdn9ZTOJkk+FWpWiBoS2lSh2gXm0NtrqOF7/s3ZL2IQ+552tQ== 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 4VpKcL3vM2z1DRD; Tue, 28 May 2024 04:42:10 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 44S4gAgU049877; Tue, 28 May 2024 04:42:10 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 44S4gAFb049874; Tue, 28 May 2024 04:42:10 GMT (envelope-from git) Date: Tue, 28 May 2024 04:42:10 GMT Message-Id: <202405280442.44S4gAFb049874@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Zhenlei Huang Subject: git: f183abd1286a - stable/13 - compat_freebsd4: Add const qualifier to the local variable s inside function freebsd4_uname() List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: zlei X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: f183abd1286a961ee1bdd3faae4048df40c37906 Auto-Submitted: auto-generated The branch stable/13 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=f183abd1286a961ee1bdd3faae4048df40c37906 commit f183abd1286a961ee1bdd3faae4048df40c37906 Author: Zhenlei Huang AuthorDate: 2024-05-28 04:21:20 +0000 Commit: Zhenlei Huang CommitDate: 2024-05-28 04:37:42 +0000 compat_freebsd4: Add const qualifier to the local variable s inside function freebsd4_uname() This local variable s is for iterating characters of global variable `version`. The content of `version` is not going to be altered by function freebsd4_uname(). MFC after: 1 week (cherry picked from commit 92f2a4c820fea9efcb6ee6a7029495c8152958c1) (cherry picked from commit 5fd1902b0c768fa43d3d7eebf7efd0957d5e144f) --- sys/kern/kern_xxx.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sys/kern/kern_xxx.c b/sys/kern/kern_xxx.c index ae88fc90eb7c..b51a0edaac99 100644 --- a/sys/kern/kern_xxx.c +++ b/sys/kern/kern_xxx.c @@ -325,7 +325,8 @@ freebsd4_uname(struct thread *td, struct freebsd4_uname_args *uap) { int name[2], error; size_t len; - char *s, *us; + const char *s; + char *us; name[0] = CTL_KERN; name[1] = KERN_OSTYPE;