clang fix - some minor fixes for unittests

remotes/origin/master-1.0.x
Anoop Saldanha 15 years ago committed by Victor Julien
parent bbab0f9987
commit f094523eb1

@ -2067,6 +2067,8 @@ int SigParseTest09(void) {
DetectEngineAppendSig(de_ctx, "alert tcp any any -> any any (msg:\"boo\"; sid:2; rev:1;)");
result &= (de_ctx->sig_list != NULL && de_ctx->sig_list->id == 2 &&
de_ctx->sig_list->rev == 2);
if (result == 0)
goto end;
result &= (de_ctx->sig_list->next != NULL && de_ctx->sig_list->next->id == 1 &&
de_ctx->sig_list->next->rev == 6);
if (result == 0)
@ -2075,6 +2077,8 @@ int SigParseTest09(void) {
DetectEngineAppendSig(de_ctx, "alert tcp any any -> any any (msg:\"boo\"; sid:2; rev:4;)");
result &= (de_ctx->sig_list != NULL && de_ctx->sig_list->id == 2 &&
de_ctx->sig_list->rev == 4);
if (result == 0)
goto end;
result &= (de_ctx->sig_list->next != NULL && de_ctx->sig_list->next->id == 1 &&
de_ctx->sig_list->next->rev == 6);
if (result == 0)

@ -1760,7 +1760,7 @@ static int DetectPcreTestSig01Real(int mpm_type) {
TcpSession ssn;
Packet *p = NULL;
ThreadVars th_v;
DetectEngineThreadCtx *det_ctx;
DetectEngineThreadCtx *det_ctx = NULL;
int result = 0;
Flow f;

@ -5092,7 +5092,7 @@ int SigTest24IPV4Keyword(void)
Packet p1, p2;
ThreadVars th_v;
DetectEngineThreadCtx *det_ctx;
DetectEngineThreadCtx *det_ctx = NULL;
int result = 0;
uint8_t *buf = (uint8_t *)"GET /one/ HTTP/1.0\r\n"

@ -1271,7 +1271,7 @@ int SCThresholdConfTest09(void)
Packet *p = UTHBuildPacket((uint8_t*)"lalala", 6, IPPROTO_TCP);
ThreadVars th_v;
DetectEngineThreadCtx *det_ctx;
DetectEngineThreadCtx *det_ctx = NULL;
int alerts = 0;
memset(&th_v, 0, sizeof(th_v));
@ -1364,7 +1364,7 @@ int SCThresholdConfTest10(void)
Packet *p2 = UTHBuildPacketSrcDst((uint8_t*)"lalala", 6, IPPROTO_TCP, "172.26.0.1", "172.26.0.10");
ThreadVars th_v;
DetectEngineThreadCtx *det_ctx;
DetectEngineThreadCtx *det_ctx = NULL;
int alerts = 0;
memset(&th_v, 0, sizeof(th_v));
@ -1459,7 +1459,7 @@ int SCThresholdConfTest11(void)
Packet *p = UTHBuildPacket((uint8_t*)"lalala", 6, IPPROTO_TCP);
ThreadVars th_v;
DetectEngineThreadCtx *det_ctx;
DetectEngineThreadCtx *det_ctx = NULL;
int alerts10 = 0;
int alerts11 = 0;
int alerts12 = 0;
@ -1575,7 +1575,7 @@ int SCThresholdConfTest12(void)
Packet *p = UTHBuildPacket((uint8_t*)"lalala", 6, IPPROTO_TCP);
ThreadVars th_v;
DetectEngineThreadCtx *det_ctx;
DetectEngineThreadCtx *det_ctx = NULL;
int alerts10 = 0;
int alerts11 = 0;
int alerts12 = 0;

Loading…
Cancel
Save