Fix compilation and a small memory error.

remotes/origin/master-1.0.x
Victor Julien 17 years ago
parent f684989f98
commit 18aa59b391

@ -173,7 +173,7 @@ int DetectDceIfaceMatch(ThreadVars *t, DetectEngineThreadCtx *det_ctx, Flow *f,
struct entry *item = NULL; struct entry *item = NULL;
DetectDceIfaceData *dce_data = (DetectDceIfaceData *)m->ctx; DetectDceIfaceData *dce_data = (DetectDceIfaceData *)m->ctx;
DCERPCState *dcerpc_state = (DCERPCState *)state; DCERPCState *dcerpc_state = (DCERPCState *)state;
if (dce_rpc_state == NULL) { if (dcerpc_state == NULL) {
SCLogDebug("No DCERPCState for the flow"); SCLogDebug("No DCERPCState for the flow");
return 0; return 0;
} }

@ -121,7 +121,7 @@ static inline DetectDceOpnumData *DetectDceOpnumArgParse(const char *arg)
SCLogError(SC_ERR_MEM_ALLOC, "Error allocating memory"); SCLogError(SC_ERR_MEM_ALLOC, "Error allocating memory");
goto error; goto error;
} }
memset(dod, 0, sizeof(DetectDceOpnumRange)); memset(dod, 0, sizeof(DetectDceOpnumData));
if ( (dup_str = strdup(pcre_sub_str)) == NULL) { if ( (dup_str = strdup(pcre_sub_str)) == NULL) {
SCLogError(SC_ERR_MEM_ALLOC, "Error allocating memory"); SCLogError(SC_ERR_MEM_ALLOC, "Error allocating memory");

Loading…
Cancel
Save