[RTEMS Project] #4419: TraceReaderLogQEMU.cc: Resource leak error spotted by Coverity
RTEMS trac
trac at rtems.org
Mon May 17 16:28:49 UTC 2021
#4419: TraceReaderLogQEMU.cc: Resource leak error spotted by Coverity
------------------------+--------------------
Reporter: Ryan Long | Owner: (none)
Type: defect | Status: new
Priority: normal | Milestone: 6.1
Component: tool | Version: 6
Severity: normal | Keywords:
Blocked By: | Blocking:
------------------------+--------------------
CID 1399615: Resource leak in processFile().
{{{
113 //
114 // Discard Header section
115 //
6. noescape: Resource logFile is not freed or pointed-to in
ReadUntilFound. [show details]
7. Condition !ReadUntilFound(logFile, "----------------"), taking true
branch.
116 if (! ReadUntilFound( logFile, QEMU_LOG_SECTION_END ) ) {
117 fprintf( stderr, "Unable to locate end of log file header\n" );
CID 1399615 (#2 of 2): Resource leak (RESOURCE_LEAK)8. leaked_storage:
Variable logFile going out of scope leaks the storage it points to.
118 return false;
}}}
--
Ticket URL: <http://devel.rtems.org/ticket/4419>
RTEMS Project <http://www.rtems.org/>
RTEMS Project
More information about the bugs
mailing list