projects
/
openssl.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Make the PACKET/WPACKET code available to both libcrypto and libssl
[openssl.git]
/
test
/
servername_test.c
diff --git
a/test/servername_test.c
b/test/servername_test.c
index f84c18705a9ee1559a7422247183f3fd34f32b13..3d19265db93b1f98f9e33e16442fed2fabc21f04 100644
(file)
--- a/
test/servername_test.c
+++ b/
test/servername_test.c
@@
-18,7
+18,7
@@
#include <openssl/err.h>
#include <time.h>
#include <openssl/err.h>
#include <time.h>
-#include "
../ssl/packet_locl
.h"
+#include "
internal/packet
.h"
#include "testutil.h"
#include "internal/nelem.h"
#include "testutil.h"
#include "internal/nelem.h"
@@
-35,10
+35,16
@@
static int get_sni_from_client_hello(BIO *bio, char **sni)
{
long len;
unsigned char *data;
{
long len;
unsigned char *data;
- PACKET pkt
= {0}, pkt2 = {0}, pkt3 = {0}, pkt4 = {0}, pkt5 = {0}
;
+ PACKET pkt
, pkt2, pkt3, pkt4, pkt5
;
unsigned int servname_type = 0, type = 0;
int ret = 0;
unsigned int servname_type = 0, type = 0;
int ret = 0;
+ memset(&pkt, 0, sizeof(pkt));
+ memset(&pkt2, 0, sizeof(pkt2));
+ memset(&pkt3, 0, sizeof(pkt3));
+ memset(&pkt4, 0, sizeof(pkt4));
+ memset(&pkt5, 0, sizeof(pkt5));
+
len = BIO_get_mem_data(bio, (char **)&data);
if (!TEST_true(PACKET_buf_init(&pkt, data, len))
/* Skip the record header */
len = BIO_get_mem_data(bio, (char **)&data);
if (!TEST_true(PACKET_buf_init(&pkt, data, len))
/* Skip the record header */