New Defects reported by Coverity Scan for libvirt-dbus

scan-admin at coverity.com scan-admin at coverity.com
Sun Jan 24 08:10:45 UTC 2021


Hi,

Please find the latest report on new defect(s) introduced to libvirt-dbus found with Coverity Scan.

2 new defect(s) introduced to libvirt-dbus found with Coverity Scan.


New defect(s) Reported-by: Coverity Scan
Showing 2 of 2 defect(s)


** CID 1444815:  Resource leaks  (RESOURCE_LEAK)
/src/util.c: 177 in virtDBusUtilEncodeUUID()


________________________________________________________________________________________________________
*** CID 1444815:  Resource leaks  (RESOURCE_LEAK)
/src/util.c: 177 in virtDBusUtilEncodeUUID()
171     }
172     
173     static gchar *
174     virtDBusUtilEncodeUUID(const gchar *uuid)
175     {
176         gchar *ret = g_strdup_printf("_%s", uuid);
>>>     CID 1444815:  Resource leaks  (RESOURCE_LEAK)
>>>     Variable "ret" going out of scope leaks the storage it points to.
177         return g_strdelimit(ret, "-", '_');
178     }
179     
180     static gchar *
181     virtDBusUtilDecodeUUID(const gchar *uuid)
182     {

** CID 1444814:  API usage errors  (ALLOC_FREE_MISMATCH)


________________________________________________________________________________________________________
*** CID 1444814:  API usage errors  (ALLOC_FREE_MISMATCH)
/src/domain.c: 39 in virtDBusDomainConvertBoolArrayToGuestVcpumap()
33             setPrev = set;
34     
35             if (stop)
36                 break;
37         }
38     
>>>     CID 1444814:  API usage errors  (ALLOC_FREE_MISMATCH)
>>>     Calling "g_autoptr_cleanup_generic_gfree" frees "ret" using "free" but it should have been freed using "g_string_free".
39         return ret->str;
40     }
41     
42     struct _virtDBusDomainFSInfoList {
43         virDomainFSInfoPtr *info;
44         gint count;


________________________________________________________________________________________________________
To view the defects in Coverity Scan visit, https://u15810271.ct.sendgrid.net/ls/click?upn=HRESupC-2F2Czv4BOaCWWCy7my0P0qcxCbhZ31OYv50yqXyKjvBooc6PgQklkMPQjdmVVDMOrtow9-2FCFV-2FPh1AQswBynLGBv9q-2FU-2FyPuNmXuU-3DSY3J_CkO38-2FnXVYPAlDbR1ZxdHNqvqoSWeUuqu9763V-2FVMwzJXiwo9VC4xYKldej12Q9RZeuVLUtgtZ2uPy86-2B9J8UHZv9GBZL9K5jDzFPeCajRpO9U-2Bvn5CXGRdfdK1jqlhQ7tbAuF5QgeC37hjjxm5UZF-2BmyK29Nhn21orPwTI1BzGxOCnmOlh5BHjbYYFpHrKD0x-2BDVJCTsAPKqE-2BQGr30excceEa5WKB5KUbIdAsKgaw-3D




More information about the Libvirt-ci mailing list