From 99d12434dd83bdea418937b82af755d0b36594ef Mon Sep 17 00:00:00 2001 From: Dirk Date: Fri, 1 Dec 2017 20:09:16 +0100 Subject: [PATCH] fix strip_*_space() --- testssl.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/testssl.sh b/testssl.sh index d9c60cc..b749012 100755 --- a/testssl.sh +++ b/testssl.sh @@ -1090,10 +1090,10 @@ strip_spaces() { # https://web.archive.org/web/20121022051228/http://codesnippets.joyent.com/posts/show/1816 strip_leading_space() { - echo "${1#"${1%%[\![:space:]]*}"}" + printf "%s" "${1#"${1%%[![:space:]]*}"}" } strip_trailing_space() { - echo "${1%"${1##*[![:space:]]}"}" + printf "%s" "${1%"${1##*[![:space:]]}"}" }