Project

General

Profile

Actions

Bug #3640

closed

coverity: leak in fast.log setup error path

Added by Victor Julien about 4 years ago. Updated almost 4 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Target version:
Affected Versions:
Effort:
Difficulty:
Label:

Description

*** CID 1461698:  Resource leaks  (RESOURCE_LEAK)
/src/alert-fastlog.c: 242 in AlertFastLogInitCtx()
236             LogFileFreeCtx(logfile_ctx);
237             return result;
238         }
239     
240         OutputCtx *output_ctx = SCCalloc(1, sizeof(OutputCtx));
241         if (unlikely(output_ctx == NULL))
>>>     CID 1461698:  Resource leaks  (RESOURCE_LEAK)
>>>     Variable "logfile_ctx" going out of scope leaks the storage it points to.
242             return result;
243         output_ctx->data = logfile_ctx;
244         output_ctx->DeInit = AlertFastLogDeInitCtx;
245     
246         result.ctx = output_ctx;
247         result.ok = true;
Actions

Also available in: Atom PDF