mirror of
https://github.com/libvirt/libvirt.git
synced 2026-10-02 12:20:06 -05:00
Resolve Coverity complaint in storagevolxml2argvtest
Ignore NULL pool in testSetVolumeType to silence Coverity, even though we only call it with NULL pool when vol is also NULL. (13) Event var_deref_model: Passing null pointer "inputpool" to function "testSetVolumeType(virStorageVolDefPtr, virStoragePoolDefPtr)", which dereferences it. [details] Also see events: [assign_zero] 95 testSetVolumeType(inputvol, inputpool);
This commit is contained in:
1 parent
4d59d5a7d2
commit
99d3a60b1f
1 file changed
+1
-1
@@ -16,7 +16,7 @@ static void
|
||||
testSetVolumeType(virStorageVolDefPtr vol,
|
||||
virStoragePoolDefPtr pool)
|
||||
{
|
||||
if (!vol)
|
||||
if (!vol || !pool)
|
||||
return;
|
||||
|
||||
switch (pool->type) {
|
||||
|
||||
Reference in new issue
Block a user