summaryrefslogtreecommitdiff
path: root/test/src
diff options
context:
space:
mode:
authorJeremy Harris <jgh146exb@wizmail.org>2015-11-28 23:29:24 +0000
committerJeremy Harris <jgh146exb@wizmail.org>2015-11-28 23:45:18 +0000
commit8dbb958ad5ddcbad39134a9652a0f575b80381ec (patch)
tree2185058357de6e67dffcdd0b693669f85972ecd5 /test/src
parentb90a2240cb6230e2c8558b26f6663a6ee60ebd70 (diff)
Testsuite: permit "client" utility to pass trailing spaces from script input lines
Diffstat (limited to 'test/src')
-rw-r--r--test/src/client.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/test/src/client.c b/test/src/client.c
index ee00912bc..ac9a965e0 100644
--- a/test/src/client.c
+++ b/test/src/client.c
@@ -841,8 +841,9 @@ if (tls_on_connect)
while (fgets(CS outbuffer, sizeof(outbuffer), stdin) != NULL)
{
int n = (int)strlen(CS outbuffer);
- while (n > 0 && isspace(outbuffer[n-1])) n--;
- outbuffer[n] = 0;
+
+ /* Strip trailing newline */
+ if (outbuffer[n-1] == '\n') outbuffer[--n] = 0;
/* Expect incoming */