From nobody Sun May 26 05:44:18 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 4Vn74z1jXcz4fkSd; Sun, 26 May 2024 05:44:19 +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 4Vn74z0SGHz4mrY; Sun, 26 May 2024 05:44:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1716702259; 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=ZXSojnX3gUMvADZLOYZd7NROmVYIve1pIdMr5nFif3M=; b=ZpEujaqwvmAViazdJ73Yn/Y5IQ+t3tLt5H6kMWwjQiL9Q79IfvwPd7Ycf19M9hTF3WnI7z P6aE8YYp9PhO7MEATYFteoNP5VzLLSvELjtqQ9SA9g0Tf/wXeUdg98/zjl/2KdISXuPqpI /uyYWp5j74PWfax+FTxvMAAzQgZzWC9OnW+qlm/9h7YjtQ73Qq6sT2Y+NdDgzPxMR7Gtr4 m2UgFYhAF39iVbn+Dax+I11VeELIrRhvJioFVhjc+SkATa7cPqIIL9NweQke/x1RoYmbAw +gwOdc0oHorqDXhr3VpnF2Y0baszee1cUvXJsgYhMAsp19NJEwR3U6LZ5tu3NQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1716702259; a=rsa-sha256; cv=none; b=neEpSm4BJizuSz/AESSkgaDBAkRQ4zjnlBTXDFYwP6MoQI48Y3UqtbS7qnhSXta41jEHMn cEFhAR3YeyKkayQcreZSw/SDxj53QjQe+dmFWma2zMFobOWjYd4kymAtsr6s+BKACk62he bmbP6NxeCH8kznKbpmxwszR08Kv4P0bBLxL8ImefO44b0ePgroo8QFP29k38Qlpl4GI69d OGEQkeP8v8z3sLjtTLP9mY9Md8bCIliBNlxYrMKVJ5Kw9UklOylAgH3Oyeu7x9Ej9x+4ZC 4mbGkCKapvEgRpd1/CSPoWIXD2WwTnYBRogrQKdIAFgbINYtO/CI1VeTrlKzWQ== 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=1716702259; 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=ZXSojnX3gUMvADZLOYZd7NROmVYIve1pIdMr5nFif3M=; b=sScUCdHkId7AwFJSpfuWrGurYQQeewMWQwhRuZ7lZEhRK4gp91mMpp2/BtsWNKr5+Awexv T15ZdthmQhYRAc+8FYAAk5Rn4ru7VBoWmsjADP94a/H0sXzg1BvAuIiwCAy9EQjqv0KSIF efyX7shx0AZKf/eWsFznwipKW8Q4x32uCEKYFYb7gcbvW9R8gixea/euUYc9b0ejOCf2O0 VVna743RaDb9pgyZEK3pQN33fsX1XwY7BQ+kwh5jlR7TnDvSrCOyX3by7BD5mJzGlVzHKG pTaVtwmUCIrDFoMDrrJ9039ImtpENi4Fdi2PZ3mXZkIVmI8VV2fj3az7m+wopQ== 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 4Vn74y6svgzp9M; Sun, 26 May 2024 05:44:18 +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 44Q5iISv076853; Sun, 26 May 2024 05:44:18 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 44Q5iIEY076850; Sun, 26 May 2024 05:44:18 GMT (envelope-from git) Date: Sun, 26 May 2024 05:44:18 GMT Message-Id: <202405260544.44Q5iIEY076850@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Wolfram Schneider Subject: git: 36294c97c147 - stable/13 - man: the exists function needs to validate the first parameter 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: wosch X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 36294c97c147733c3f4408cb6ecfacb8de8cc282 Auto-Submitted: auto-generated The branch stable/13 has been updated by wosch: URL: https://cgit.FreeBSD.org/src/commit/?id=36294c97c147733c3f4408cb6ecfacb8de8cc282 commit 36294c97c147733c3f4408cb6ecfacb8de8cc282 Author: Wolfram Schneider AuthorDate: 2024-05-20 16:02:21 +0000 Commit: Wolfram Schneider CommitDate: 2024-05-26 05:43:45 +0000 man: the exists function needs to validate the first parameter This fixes an issue with the ".so " macro for FreeBSD ports manual pages. PR: 275978 Reported by: Jamie Landeg-Jones MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D45231 (discussion) --- usr.bin/man/man.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/usr.bin/man/man.sh b/usr.bin/man/man.sh index ca9b002dfc08..33be10cd5bd6 100755 --- a/usr.bin/man/man.sh +++ b/usr.bin/man/man.sh @@ -195,6 +195,10 @@ decho() { # Returns true if glob resolves to a real file and store the first # found filename in the variable $found exists() { + if [ -z "$1" ]; then + return 1 + fi + local IFS # Don't accidentally inherit callers IFS (breaks perl manpages)