Mike Frysinger
2016-Dec-19 20:59 UTC
[PATCH] regress/allow-deny-users.sh: fix bashism in test
The test command uses = for string compares, not ==. Using some POSIX shells will reject this statement with an error about an unknown operator. --- regress/allow-deny-users.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/regress/allow-deny-users.sh b/regress/allow-deny-users.sh index 32a269afa97c..86805e19322b 100644 --- a/regress/allow-deny-users.sh +++ b/regress/allow-deny-users.sh @@ -4,7 +4,7 @@ tid="AllowUsers/DenyUsers" me="$LOGNAME" -if [ "x$me" == "x" ]; then +if [ "x$me" = "x" ]; then me=`whoami` fi other="nobody" -- 2.11.0.rc2
Damien Miller
2016-Dec-19 22:35 UTC
[PATCH] regress/allow-deny-users.sh: fix bashism in test
applied - thanks On Mon, 19 Dec 2016, Mike Frysinger wrote:> The test command uses = for string compares, not ==. Using some POSIX > shells will reject this statement with an error about an unknown operator. > --- > regress/allow-deny-users.sh | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/regress/allow-deny-users.sh b/regress/allow-deny-users.sh > index 32a269afa97c..86805e19322b 100644 > --- a/regress/allow-deny-users.sh > +++ b/regress/allow-deny-users.sh > @@ -4,7 +4,7 @@ > tid="AllowUsers/DenyUsers" > > me="$LOGNAME" > -if [ "x$me" == "x" ]; then > +if [ "x$me" = "x" ]; then > me=`whoami` > fi > other="nobody" > -- > 2.11.0.rc2 > > _______________________________________________ > openssh-unix-dev mailing list > openssh-unix-dev at mindrot.org > https://lists.mindrot.org/mailman/listinfo/openssh-unix-dev >