New Defects reported by Coverity Scan for libvirt
by scan-admin@coverity.com
Hi,
Please find the latest report on new defect(s) introduced to libvirt found with Coverity Scan.
2 new defect(s) introduced to libvirt found with Coverity Scan.
New defect(s) Reported-by: Coverity Scan
Showing 2 of 2 defect(s)
** CID 417227: Null pointer dereferences (NULL_RETURNS)
/src/qemu/qemu_nbdkit.c: 974 in qemuNbdkitProcessBuildCommandAuth()
________________________________________________________________________________________________________
*** CID 417227: Null pointer dereferences (NULL_RETURNS)
/src/qemu/qemu_nbdkit.c: 974 in qemuNbdkitProcessBuildCommandAuth()
968 _("invalid secret type %1$s"),
969 authdef->secrettype);
970 return -1;
971 }
972
973 conn = virGetConnectSecret();
>>> CID 417227: Null pointer dereferences (NULL_RETURNS)
>>> Dereferencing a pointer that might be "NULL" "conn" when calling "virSecretGetSecretString". (The dereference is assumed on the basis of the "nonnull" parameter attribute.)
974 if (virSecretGetSecretString(conn,
975 &authdef->seclookupdef,
976 secrettype,
977 &secret,
978 &secretlen) < 0)
979 return -1;
** CID 417226: Error handling issues (CHECKED_RETURN)
/src/qemu/qemu_nbdkit.c: 1284 in qemuNbdkitProcessStop()
________________________________________________________________________________________________________
*** CID 417226: Error handling issues (CHECKED_RETURN)
/src/qemu/qemu_nbdkit.c: 1284 in qemuNbdkitProcessStop()
1278 qemuSecurityDomainRestorePathLabel(driver, vm, proc->source->ssh_agent);
1279
1280 if (proc->pid < 0)
1281 return 0;
1282
1283 VIR_DEBUG("Stopping nbdkit process %i", proc->pid);
>>> CID 417226: Error handling issues (CHECKED_RETURN)
>>> Calling "virProcessKill" without checking return value (as is done elsewhere 8 out of 10 times).
1284 virProcessKill(proc->pid, SIGTERM);
1285
1286 unlink(proc->pidfile);
1287 unlink(proc->socketfile);
1288 proc->pid = -1;
1289
1290 return 0;
________________________________________________________________________________________________________
To view the defects in Coverity Scan visit, https://u15810271.ct.sendgrid.net/ls/click?upn=HRESupC-2F2Czv4BOaCWWCy7my...
1 year
New Defects reported by Coverity Scan for libvirt
by scan-admin@coverity.com
Hi,
Please find the latest report on new defect(s) introduced to libvirt found with Coverity Scan.
1 new defect(s) introduced to libvirt found with Coverity Scan.
New defect(s) Reported-by: Coverity Scan
Showing 1 of 1 defect(s)
** CID 417220: Error handling issues (CHECKED_RETURN)
/examples/c/misc/event-test.c: 1096 in myNetworkEventMetadataChangeCallback()
________________________________________________________________________________________________________
*** CID 417220: Error handling issues (CHECKED_RETURN)
/examples/c/misc/event-test.c: 1096 in myNetworkEventMetadataChangeCallback()
1090 int type,
1091 const char *nsuri,
1092 void *opaque G_GNUC_UNUSED)
1093 {
1094 const char *typestr = networkMetadataTypeToStr(type);
1095 char uuid[VIR_UUID_STRING_BUFLEN];
>>> CID 417220: Error handling issues (CHECKED_RETURN)
>>> Calling "virNetworkGetUUIDString" without checking return value (as is done elsewhere 4 out of 5 times).
1096 virNetworkGetUUIDString(net, uuid);
1097
1098 printf("%s EVENT: Network: (%s) uuid: (%s) metadata type: (%s) nsuri: (%s)\n",
1099 __func__, virNetworkGetName(net), uuid, typestr, nsuri ? nsuri : "n/a");
1100
1101 return 0;
________________________________________________________________________________________________________
To view the defects in Coverity Scan visit, https://u15810271.ct.sendgrid.net/ls/click?upn=HRESupC-2F2Czv4BOaCWWCy7my...
1 year