[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] New Defects reported by Coverity Scan for XenProject
>>> On 4/2/2015 at 08:32 AM, Ian Campbell <ian.campbell@xxxxxxxxxx> wrote: > Hi Charles, > > I'm not sure if this is a real issue in the qdisk support for xenstat, > but I think it may relate to the first return 0 in qmp_read which may > not free the accumulated array. Yes. That is a leak on the failure case. > > Could you take a look please? Patch sent, Thanks - Charles > > Ian. > > On Wed, 2015-04-01 at 05:51 -0700, scan-admin@xxxxxxxxxxxx wrote: >> Hi, >> >> Please find the latest report on new defect(s) introduced to XenProject > found with Coverity Scan. >> >> 1 new defect(s) introduced to XenProject found with Coverity Scan. >> 2 defect(s), reported by Coverity Scan earlier, were marked fixed in the > recent build analyzed by Coverity Scan. >> >> New defect(s) Reported-by: Coverity Scan >> Showing 1 of 1 defect(s) >> >> >> ** CID 1292691: Resource leaks (RESOURCE_LEAK) >> /tools/xenstat/libxenstat/src/xenstat_qmp.c: 327 in qmp_query() >> >> >> > _____________________________________________________________________________ > ___________________________ >> *** CID 1292691: Resource leaks (RESOURCE_LEAK) >> /tools/xenstat/libxenstat/src/xenstat_qmp.c: 327 in qmp_query() >> 321 int n; >> 322 >> 323 n = strlen(cmd); >> 324 if (qmp_write(qfd, cmd, n) != n) >> 325 return NULL; >> 326 if (!qmp_read(qfd, &qstats)) >> >>> CID 1292691: Resource leaks (RESOURCE_LEAK) >> >>> Variable "qstats" going out of scope leaks the storage it points to. >> 327 return NULL; >> 328 return qstats; >> 329 } >> 330 >> 331 /* Returns a socket connected to the QMP socket. Returns -1 on > failure. */ >> 332 static int qmp_connect(char *path) >> >> >> > _____________________________________________________________________________ > ___________________________ >> To view the defects in Coverity Scan visit, > https://scan.coverity.com/projects/606?tab=overview >> >> To manage Coverity Scan email notifications for "ian.campbell@xxxxxxxxxx", > click > https://scan.coverity.com/subscriptions/edit?email=ian.campbell%40citrix.com&t > oken=1ce0fc428b9f94f66fd8d1ecf6cbb76a . >> _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |