mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-01-09 01:18:00 +03:00
Drop magic comments for coverity
They were added mostly randomly and we don't really want to keep working around of false positives. Signed-off-by: Peter Krempa <pkrempa@redhat.com> Reviewed-by: Pavel Hrdina <phrdina@redhat.com> Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
This commit is contained in:
parent
fac773fab9
commit
bbd55e9284
@ -17421,7 +17421,6 @@ virDomainFeaturesDefParse(virDomainDef *def,
|
||||
break;
|
||||
}
|
||||
|
||||
/* coverity[dead_error_begin] */
|
||||
case VIR_DOMAIN_FEATURE_LAST:
|
||||
break;
|
||||
}
|
||||
@ -17509,7 +17508,6 @@ virDomainFeaturesDefParse(virDomainDef *def,
|
||||
}
|
||||
break;
|
||||
|
||||
/* coverity[dead_error_begin] */
|
||||
case VIR_DOMAIN_HYPERV_LAST:
|
||||
break;
|
||||
}
|
||||
@ -17564,7 +17562,6 @@ virDomainFeaturesDefParse(virDomainDef *def,
|
||||
def->kvm_features[feature] = value;
|
||||
break;
|
||||
|
||||
/* coverity[dead_error_begin] */
|
||||
case VIR_DOMAIN_KVM_LAST:
|
||||
break;
|
||||
}
|
||||
@ -17609,7 +17606,6 @@ virDomainFeaturesDefParse(virDomainDef *def,
|
||||
return -1;
|
||||
break;
|
||||
|
||||
/* coverity[dead_error_begin] */
|
||||
case VIR_DOMAIN_XEN_LAST:
|
||||
break;
|
||||
}
|
||||
@ -21541,7 +21537,6 @@ virDomainDefFeaturesCheckABIStability(virDomainDef *src,
|
||||
}
|
||||
break;
|
||||
|
||||
/* coverity[dead_error_begin] */
|
||||
case VIR_DOMAIN_HYPERV_LAST:
|
||||
break;
|
||||
}
|
||||
@ -21586,7 +21581,6 @@ virDomainDefFeaturesCheckABIStability(virDomainDef *src,
|
||||
}
|
||||
break;
|
||||
|
||||
/* coverity[dead_error_begin] */
|
||||
case VIR_DOMAIN_XEN_LAST:
|
||||
break;
|
||||
}
|
||||
@ -21612,7 +21606,6 @@ virDomainDefFeaturesCheckABIStability(virDomainDef *src,
|
||||
|
||||
break;
|
||||
|
||||
/* coverity[dead_error_begin] */
|
||||
case VIR_DOMAIN_KVM_LAST:
|
||||
break;
|
||||
}
|
||||
@ -27575,7 +27568,6 @@ virDomainDefFormatFeatures(virBuffer *buf,
|
||||
def->hyperv_vendor_id);
|
||||
break;
|
||||
|
||||
/* coverity[dead_error_begin] */
|
||||
case VIR_DOMAIN_HYPERV_LAST:
|
||||
break;
|
||||
}
|
||||
@ -27602,7 +27594,6 @@ virDomainDefFormatFeatures(virBuffer *buf,
|
||||
def->kvm_features[j]));
|
||||
break;
|
||||
|
||||
/* coverity[dead_error_begin] */
|
||||
case VIR_DOMAIN_KVM_LAST:
|
||||
break;
|
||||
}
|
||||
@ -27644,7 +27635,6 @@ virDomainDefFormatFeatures(virBuffer *buf,
|
||||
}
|
||||
break;
|
||||
|
||||
/* coverity[dead_error_begin] */
|
||||
case VIR_DOMAIN_XEN_LAST:
|
||||
break;
|
||||
}
|
||||
@ -27738,7 +27728,6 @@ virDomainDefFormatFeatures(virBuffer *buf,
|
||||
virDomainIBSTypeToString(def->features[i]));
|
||||
break;
|
||||
|
||||
/* coverity[dead_error_begin] */
|
||||
case VIR_DOMAIN_FEATURE_LAST:
|
||||
break;
|
||||
}
|
||||
@ -29592,7 +29581,6 @@ virDomainObjGetMetadata(virDomainObj *vm,
|
||||
return NULL;
|
||||
break;
|
||||
|
||||
/* coverity[dead_error_begin] */
|
||||
case VIR_DOMAIN_METADATA_LAST:
|
||||
break;
|
||||
}
|
||||
@ -29674,7 +29662,6 @@ virDomainDefSetMetadata(virDomainDef *def,
|
||||
}
|
||||
break;
|
||||
|
||||
/* coverity[dead_error_begin] */
|
||||
case VIR_DOMAIN_METADATA_LAST:
|
||||
break;
|
||||
}
|
||||
|
@ -1376,7 +1376,6 @@ x86ModelFromCPU(const virCPUDef *cpu,
|
||||
x86DataSubtract(&model->data, &feature->data);
|
||||
break;
|
||||
|
||||
/* coverity[dead_error_condition] */
|
||||
case VIR_CPU_FEATURE_OPTIONAL:
|
||||
case VIR_CPU_FEATURE_LAST:
|
||||
break;
|
||||
|
@ -6606,7 +6606,6 @@ qemuBuildCpuCommandLine(virCommand *cmd,
|
||||
def->hyperv_vendor_id);
|
||||
break;
|
||||
|
||||
/* coverity[dead_error_begin] */
|
||||
case VIR_DOMAIN_HYPERV_LAST:
|
||||
break;
|
||||
}
|
||||
@ -6638,7 +6637,6 @@ qemuBuildCpuCommandLine(virCommand *cmd,
|
||||
virBufferAddLit(&buf, ",kvm-poll-control=on");
|
||||
break;
|
||||
|
||||
/* coverity[dead_error_begin] */
|
||||
case VIR_DOMAIN_KVM_LAST:
|
||||
break;
|
||||
}
|
||||
|
@ -8989,7 +8989,6 @@ qemuDomainGetNumaParameters(virDomainPtr dom,
|
||||
nodeset = NULL;
|
||||
break;
|
||||
|
||||
/* coverity[dead_error_begin] */
|
||||
default:
|
||||
break;
|
||||
/* should not hit here */
|
||||
@ -10556,7 +10555,6 @@ qemuDomainGetInterfaceParameters(virDomainPtr dom,
|
||||
if (net->bandwidth && net->bandwidth->out)
|
||||
params[i].value.ui = net->bandwidth->out->burst;
|
||||
break;
|
||||
/* coverity[dead_error_begin] */
|
||||
default:
|
||||
break;
|
||||
/* should not hit here */
|
||||
|
@ -4244,7 +4244,6 @@ qemuProcessVerifyHypervFeatures(virDomainDef *def,
|
||||
virDomainHypervTypeToString(i));
|
||||
return -1;
|
||||
|
||||
/* coverity[dead_error_begin] */
|
||||
case VIR_DOMAIN_HYPERV_SPINLOCKS:
|
||||
case VIR_DOMAIN_HYPERV_VENDOR_ID:
|
||||
case VIR_DOMAIN_HYPERV_LAST:
|
||||
|
@ -5643,7 +5643,6 @@ remoteStreamEventAddCallback(virStreamPtr st,
|
||||
|
||||
cleanup:
|
||||
remoteDriverUnlock(priv);
|
||||
/* coverity[leaked_storage] - cbdata is not leaked */
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
@ -131,7 +131,6 @@ int main(int argc, char **argv)
|
||||
content = "free";
|
||||
else if (part->type & PED_PARTITION_METADATA)
|
||||
content = "metadata";
|
||||
/* coverity[dead_error_condition] - not true if defined */
|
||||
else if (part->type & PED_PARTITION_PROTECTED)
|
||||
content = "protected";
|
||||
else
|
||||
@ -145,7 +144,6 @@ int main(int argc, char **argv)
|
||||
content = "free";
|
||||
else if (part->type & PED_PARTITION_METADATA)
|
||||
content = "metadata";
|
||||
/* coverity[dead_error_condition] - not true if defined */
|
||||
else if (part->type & PED_PARTITION_PROTECTED)
|
||||
content = "protected";
|
||||
else
|
||||
|
@ -2750,7 +2750,6 @@ static int virNetDevParseMcast(char *buf, virNetDevMcastEntry *mcast)
|
||||
}
|
||||
break;
|
||||
|
||||
/* coverity[dead_error_begin] */
|
||||
case VIR_MCAST_TYPE_LAST:
|
||||
break;
|
||||
}
|
||||
|
@ -521,7 +521,6 @@ virProcessGetAffinity(pid_t pid)
|
||||
ret = virBitmapNew(ncpus);
|
||||
|
||||
for (i = 0; i < ncpus; i++) {
|
||||
/* coverity[overrun-local] */
|
||||
if (CPU_ISSET_S(i, masklen, mask))
|
||||
ignore_value(virBitmapSetBit(ret, i));
|
||||
}
|
||||
|
@ -1206,7 +1206,6 @@ mymain(void)
|
||||
virinitret = virInitialize();
|
||||
|
||||
/* Phase two of killing interfering fds; see above. */
|
||||
/* coverity[overwrite_var] - silence the obvious */
|
||||
fd = 3;
|
||||
VIR_FORCE_CLOSE(fd);
|
||||
fd = 4;
|
||||
|
@ -38,7 +38,6 @@ static int testDriverModule(const void *args)
|
||||
{
|
||||
const struct testDriverModuleData *data = args;
|
||||
|
||||
/* coverity[leaked_storage] */
|
||||
if (virDriverLoadModule(data->module, data->regfunc, true) != 0)
|
||||
return -1;
|
||||
|
||||
|
@ -96,7 +96,6 @@ virshCatchDisconnect(virConnectPtr conn,
|
||||
case VIR_CONNECT_CLOSE_REASON_KEEPALIVE:
|
||||
str = N_("Disconnected from %s due to keepalive timeout");
|
||||
break;
|
||||
/* coverity[dead_error_condition] */
|
||||
case VIR_CONNECT_CLOSE_REASON_CLIENT:
|
||||
case VIR_CONNECT_CLOSE_REASON_LAST:
|
||||
break;
|
||||
|
@ -92,7 +92,6 @@ vshAdmCatchDisconnect(virAdmConnectPtr conn G_GNUC_UNUSED,
|
||||
case VIR_CONNECT_CLOSE_REASON_KEEPALIVE:
|
||||
str = N_("Disconnected from %s due to keepalive timeout");
|
||||
break;
|
||||
/* coverity[dead_error_condition] */
|
||||
case VIR_CONNECT_CLOSE_REASON_CLIENT:
|
||||
case VIR_CONNECT_CLOSE_REASON_LAST:
|
||||
break;
|
||||
|
Loading…
Reference in New Issue
Block a user