From nobody Wed Apr 17 02:08:49 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 4VK48L20rqz5HZ3t; Wed, 17 Apr 2024 02:08:50 +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 4VK48L1Lvyz4H6W; Wed, 17 Apr 2024 02:08:50 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1713319730; 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=WbICc+UVSM0lBepTbLaBEwSNTUbn2ZJ/Kdi+OqGd21g=; b=Dr3zs5t9a82n63zU5mg3XTBbXYtr1yjtdEv7bgfmRD9JdX5H+pSjrdBw/6i+k6Df9LWJqz oJBAGP9LBIsjF0EVc+4yfxk/ORJ+i7RiMqBAlvcfca9bqPFS0b7E4ykqzZWjkeBGoGNmh5 fxzsJiD+p+z9Z9+9t1978IiKZok0FBEv1EZdpN92ztq24b4ZqiIniShsMkbu8WME35ZkVm E9XBkaascLvMMHYl9r5NhsXkNTTYhXMMSeWtNnNLQ+6aaCNpej2veT6kqvYhPNXgT3M9bd dLNIWZJ6NLyQgJnYpYH9e7+2Gv4f18Yv2YyoJZTB0Y4q5PPHCgtyxHVDEL2ddw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1713319730; a=rsa-sha256; cv=none; b=oe2PASOBcxAqce5/klxpJ1W698kXeaGpPNr0Cm85ZTlaJ2P2VlYnQe3QcrITxGNRhOagQO EpFSMSZYzMwzcoazB0kli9y523fNxX+C5MK3Xjj7K1y/NrfWXtAwYEt641WNUqvjcs0duc lWXHNTZn854ZJZwvkjgV3hQVlDxHhM2MVojpNyzuu7i1SvFzf0MLAjWsHfHyJ4VtU4BjeT L90E/aTC3EFtF6iMAUFkC0aBYbc1EpED2N2wtqv4BIyu9j/YK66DTIhpukiQSEwX/UoD3d xOPYtl+f9eAL6MZHTwkq7kLCe4G3hl/HC7o5Uyks2ohiuOO55mVgntnryLKzcQ== 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=1713319730; 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=WbICc+UVSM0lBepTbLaBEwSNTUbn2ZJ/Kdi+OqGd21g=; b=UrtWUSPgu6yDAOSSrQbfPZbZD9g0sUk36NWUeU0VoMG5ky+uGCoig3MY2ZO4WdgAaYkTWU t7QV0uf0WEKXmBtHZ5+izvYhsOQeHKwBJlIzaa936uAlQTWYiOQpqGgVxml9DTzo/Q5qRj DZClHBYqEIiLDZi3147hjj/UOYunqcJWRsZez+2fxxsRWd7z206r6D+f1UW7NWFWCps3fM Epvaxt2syXT0lZduUlLkMeOwXlbtCoYGrWw0geYQPmemXHdzx6o+P4co6pg3GKtxhOr9QQ 5baJsNU8hfM1QPoU5uoR2abtCoufbSBp8fhWj7DF3cvCPPcafysgfIGmpD2vew== 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 4VK48L0d9Vz16mL; Wed, 17 Apr 2024 02:08:50 +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 43H28n9P034727; Wed, 17 Apr 2024 02:08:49 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43H28nY4034724; Wed, 17 Apr 2024 02:08:49 GMT (envelope-from git) Date: Wed, 17 Apr 2024 02:08:49 GMT Message-Id: <202404170208.43H28nY4034724@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Dag-Erling =?utf-8?Q?Sm=C3=B8rgrav?= Subject: git: f070188c3ad6 - main - cp: Use warnc(). 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: des X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: f070188c3ad6b87ee9ce220b21718333d1bd9d52 Auto-Submitted: auto-generated The branch main has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=f070188c3ad6b87ee9ce220b21718333d1bd9d52 commit f070188c3ad6b87ee9ce220b21718333d1bd9d52 Author: Dag-Erling Smørgrav AuthorDate: 2024-04-17 02:07:20 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2024-04-17 02:08:38 +0000 cp: Use warnc(). MFC after: 1 week Sponsored by: Klara, Inc. --- bin/cp/cp.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/bin/cp/cp.c b/bin/cp/cp.c index 98697ba2b06f..823376964bd1 100644 --- a/bin/cp/cp.c +++ b/bin/cp/cp.c @@ -287,8 +287,7 @@ copy(char *argv[], enum op type, int fts_options, struct stat *root_stat) case FTS_NS: case FTS_DNR: case FTS_ERR: - warnx("%s: %s", - curr->fts_path, strerror(curr->fts_errno)); + warnc(curr->fts_errno, "%s", curr->fts_path); badcp = rval = 1; continue; case FTS_DC: /* Warn, continue. */