From 3e26a7c96254806602086301333ed64ebed6c38a Mon Sep 17 00:00:00 2001 From: merakor Date: Mon, 28 Feb 2022 18:11:14 +0000 Subject: _readlinkf(): do not run under subshell FossilOrigin-Name: 25e6e10ed50b47d1367df83c93cbbdf8b25408d4eeb0aca60e0bc9c9f20fc3b4 --- src/cpt-lib.in | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/cpt-lib.in b/src/cpt-lib.in index 9b71eab..d8fd262 100644 --- a/src/cpt-lib.in +++ b/src/cpt-lib.in @@ -172,7 +172,7 @@ _stat() ( printf '%s' "$_user" ) -_readlinkf() ( +_readlinkf() { # Public domain POSIX sh readlink function by Koichi Nakashima [ "${1:-}" ] || return 1 max_symlinks=40 @@ -206,7 +206,7 @@ _readlinkf() ( target=${link#*" $target -> "} done return 1 -) +} _get_digest() { # Get digest algorithm from the given file. It looks for a header on the -- cgit v1.2.3