aboutsummaryrefslogtreecommitdiff
path: root/openssl/ssl/heartbeat_test.c
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2014-09-02 18:24:12 +0200
committermarha <marha@users.sourceforge.net>2014-09-02 18:26:00 +0200
commit04168ae281bfbd714ddf6b90d98eac892508dde8 (patch)
treec2d7e42dede9c0b9930ce537eb7d804e45459e53 /openssl/ssl/heartbeat_test.c
parente21655632e3fd40b7f6a5cc3c7f3c379d54557c4 (diff)
downloadvcxsrv-04168ae281bfbd714ddf6b90d98eac892508dde8.tar.gz
vcxsrv-04168ae281bfbd714ddf6b90d98eac892508dde8.tar.bz2
vcxsrv-04168ae281bfbd714ddf6b90d98eac892508dde8.zip
Upgrade openssl to version openssl-1.0.1i
Diffstat (limited to 'openssl/ssl/heartbeat_test.c')
-rw-r--r--openssl/ssl/heartbeat_test.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/openssl/ssl/heartbeat_test.c b/openssl/ssl/heartbeat_test.c
index d8cc55998..de9d39761 100644
--- a/openssl/ssl/heartbeat_test.c
+++ b/openssl/ssl/heartbeat_test.c
@@ -38,13 +38,17 @@
* http://mike-bland.com/tags/heartbleed.html
*/
+#define OPENSSL_UNIT_TEST
+
+#include "../test/testutil.h"
+
#include "../ssl/ssl_locl.h"
#include <ctype.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
-#if !defined(OPENSSL_NO_HEARTBEATS) && !defined(OPENSSL_SYS_WINDOWS)
+#if !defined(OPENSSL_NO_HEARTBEATS) && !defined(OPENSSL_NO_UNIT_TEST)
/* As per https://tools.ietf.org/html/rfc6520#section-4 */
#define MIN_PADDING_SIZE 16
@@ -263,13 +267,10 @@ static int honest_payload_size(unsigned char payload_buf[])
}
#define SETUP_HEARTBEAT_TEST_FIXTURE(type)\
- HEARTBEAT_TEST_FIXTURE fixture = set_up_##type(__func__);\
- int result = 0
+ SETUP_TEST_FIXTURE(HEARTBEAT_TEST_FIXTURE, set_up_##type)
#define EXECUTE_HEARTBEAT_TEST()\
- if (execute_heartbeat(fixture) != 0) result = 1;\
- tear_down(fixture);\
- return result
+ EXECUTE_TEST(execute_heartbeat, tear_down)
static int test_dtls1_not_bleeding()
{