X-Git-Url: https://git.exim.org/users/heiko/exim.git/blobdiff_plain/0886a95e57e47c507ad3a52e3c9d3581ee7b6ddc..8c5d388a6e12d1a8bd4aa565920238f8a921414a:/test/src/client.c diff --git a/test/src/client.c b/test/src/client.c index dd7df5bd6..ac9a965e0 100644 --- a/test/src/client.c +++ b/test/src/client.c @@ -84,9 +84,9 @@ latter needs a whole pile of tables. */ # if GNUTLS_VERSION_NUMBER >= 0x030103 # define HAVE_OCSP # include -# ifndef GNUTLS_NO_EXTENSIONS -# define GNUTLS_NO_EXTENSIONS 0 -# endif +# endif +# ifndef GNUTLS_NO_EXTENSIONS +# define GNUTLS_NO_EXTENSIONS 0 # endif # define DH_BITS 768 @@ -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 */