mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-02-20 21:39:54 +00:00
simplify printf call
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
This commit is contained in:
parent
63c94a36f1
commit
a3e694c2ad
@ -30,7 +30,7 @@ print_quoted_args() {
|
||||
# but produce more human-readable results for common/simple cases like "a b"
|
||||
for a in "$@"; do
|
||||
# Get bash to quote the string
|
||||
q=$(printf '%q' "$a")
|
||||
printf -v q '%q' "$a"
|
||||
simple_pattern="^([-[:alnum:]_+./:@]+=)?([^']*)$"
|
||||
if [[ "$a" != "$q" && $a =~ $simple_pattern ]]; then
|
||||
# a requires some quoting (a != q), but has no single quotes, so we can
|
||||
|
Loading…
x
Reference in New Issue
Block a user