From 3f9ce10525849776286e5bcbc57a3f7a364b48d2 Mon Sep 17 00:00:00 2001 From: Andreas Schneider Date: Mon, 9 May 2016 15:45:45 +0200 Subject: [PATCH] tests: Fix buffer test without NARG macro support Signed-off-by: Andreas Schneider --- tests/unittests/torture_buffer.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tests/unittests/torture_buffer.c b/tests/unittests/torture_buffer.c index e29b572c..2a11c81a 100644 --- a/tests/unittests/torture_buffer.c +++ b/tests/unittests/torture_buffer.c @@ -243,7 +243,10 @@ static void torture_buffer_pack_badformat(void **state){ /* with additional format */ rc = ssh_buffer_pack(buffer, "bb", b); +#ifdef HAVE_GCC_NARG_MACRO + /* We can only detect errors if we have support for NARG macros */ assert_int_equal(rc, SSH_ERROR); +#endif /* unpack with missing format */ ssh_buffer_reinit(buffer);