summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNikos Mavrogiannopoulos <nmav@gnutls.org>2013-12-21 13:01:31 +0100
committerNikos Mavrogiannopoulos <nmav@gnutls.org>2013-12-21 13:11:16 +0100
commit7afa8a9dc659c3759d8290021b6a50f38a01757d (patch)
tree3d69e3573c469013a1c25c866dfd482511ed7946
parent7044c61961daba2d35c4338168ec2f8792177195 (diff)
downloadgnutls-7afa8a9dc659c3759d8290021b6a50f38a01757d.tar.gz
corrected some tests to operate silently under valgrind
-rw-r--r--tests/mini-dtls-large.c3
-rw-r--r--tests/mini-dtls-record.c4
-rw-r--r--tests/mini-handshake-timeout.c2
3 files changed, 5 insertions, 4 deletions
diff --git a/tests/mini-dtls-large.c b/tests/mini-dtls-large.c
index 2b5b6b2bbd..3d4f18604d 100644
--- a/tests/mini-dtls-large.c
+++ b/tests/mini-dtls-large.c
@@ -207,6 +207,9 @@ static void server(int fd)
/* see the Getting peer's information example */
/* print_info(session); */
+
+ /* avoid uninitialized warnings */
+ memset(buffer, 1, sizeof(buffer));
ret =
gnutls_record_send(session, buffer,
diff --git a/tests/mini-dtls-record.c b/tests/mini-dtls-record.c
index 37d1ebfb46..e06fa961cc 100644
--- a/tests/mini-dtls-record.c
+++ b/tests/mini-dtls-record.c
@@ -24,8 +24,6 @@
#include <config.h>
#endif
-#define REL_LAYER
-
#include <stdio.h>
#include <stdlib.h>
@@ -51,6 +49,8 @@ int main()
#include "utils.h"
+#define REL_LAYER
+
static int test_finished = 0;
static void terminate(void);
diff --git a/tests/mini-handshake-timeout.c b/tests/mini-handshake-timeout.c
index 14e7dc91cc..80e2b4e097 100644
--- a/tests/mini-handshake-timeout.c
+++ b/tests/mini-handshake-timeout.c
@@ -117,8 +117,6 @@ static void client(int fd, int wait)
success("client: expected timeout occured\n");
return;
} else {
- gnutls_bye(session, GNUTLS_SHUT_WR);
-
if (wait != 0) {
fail("client: handshake was completed unexpectedly\n");
gnutls_perror(ret);