From 573284b5ed1e78d17d183a9d3727c7788cb57dcb Mon Sep 17 00:00:00 2001 From: Victor Julien Date: Sun, 28 Feb 2016 14:29:09 +0100 Subject: [PATCH] vlan: fix bad checks in unittests --- src/decode-vlan.c | 2 +- src/stream-tcp.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/decode-vlan.c b/src/decode-vlan.c index 59495594e7..166be0ff0a 100644 --- a/src/decode-vlan.c +++ b/src/decode-vlan.c @@ -240,7 +240,7 @@ static int DecodeVLANtest03 (void) DecodeVLAN(&tv, &dtv, p, raw_vlan, sizeof(raw_vlan), NULL); - if(p->vlanh == NULL) { + if(p->vlanh[0] == NULL) { goto error; } diff --git a/src/stream-tcp.c b/src/stream-tcp.c index 4c0a81d7f2..80d1b8dffd 100644 --- a/src/stream-tcp.c +++ b/src/stream-tcp.c @@ -10253,7 +10253,7 @@ static int StreamTcpTest40(void) DecodeVLAN(&tv, &dtv, p, GET_PKT_DATA(p), GET_PKT_LEN(p), NULL); - if(p->vlanh == NULL) { + if(p->vlanh[0] == NULL) { SCFree(p); return 0; }