Skip to content

Commit

Permalink
util/mime: fix memory leak
Browse files Browse the repository at this point in the history
Fix memory leak at util-decode-mime:MimeDecInitParser, which
root cause is not-freeing allocated memory for mimeMsg

Bug: OISF#6745
  • Loading branch information
jtstrs authored and victorjulien committed Feb 10, 2024
1 parent 7e4dba7 commit 231c892
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/util-decode-mime.c
Original file line number Diff line number Diff line change
Expand Up @@ -2432,6 +2432,7 @@ MimeDecParseState * MimeDecInitParser(void *data,
PushStack(state->stack);
if (state->stack->top == NULL) {
SCFree(state->stack);
SCFree(state->msg);
SCFree(state);
return NULL;
}
Expand Down

0 comments on commit 231c892

Please sign in to comment.