From 037de004c68d704abf839eebe075c58c9603f8f3 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Mon, 20 May 2024 07:14:36 +0200 Subject: Adding upstream version 1:2.45.1. Signed-off-by: Daniel Baumann --- t/check-non-portable-shell.pl | 2 ++ 1 file changed, 2 insertions(+) (limited to 't/check-non-portable-shell.pl') diff --git a/t/check-non-portable-shell.pl b/t/check-non-portable-shell.pl index dd8107c..b2b28c2 100755 --- a/t/check-non-portable-shell.pl +++ b/t/check-non-portable-shell.pl @@ -47,6 +47,8 @@ while (<>) { /\bgrep\b.*--file\b/ and err 'grep --file FILE is not portable (use grep -f FILE)'; /\b[ef]grep\b/ and err 'egrep/fgrep obsolescent (use grep -E/-F)'; /\bexport\s+[A-Za-z0-9_]*=/ and err '"export FOO=bar" is not portable (use FOO=bar && export FOO)'; + /\blocal\s+[A-Za-z0-9_]*=\$([A-Za-z0-9_{]|[(][^(])/ and + err q(quote "$val" in 'local var=$val'); /^\s*([A-Z0-9_]+=(\w*|(["']).*?\3)\s+)+(\w+)/ and exists($func{$4}) and err '"FOO=bar shell_func" assignment extends beyond "shell_func"'; $line = ''; -- cgit v1.2.3