mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-01-12 07:42:56 +00:00
virDomainDiskDef: Change type of error_policy to virDomainDiskErrorPolicy
Signed-off-by: Tim Wiederhake <twiederh@redhat.com> Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
This commit is contained in:
parent
f86e0b4cbc
commit
90a50b98f6
@ -8976,12 +8976,16 @@ virDomainDiskDefDriverParseXML(virDomainDiskDef *def,
|
||||
}
|
||||
VIR_FREE(tmp);
|
||||
|
||||
if ((tmp = virXMLPropString(cur, "error_policy")) &&
|
||||
(def->error_policy = virDomainDiskErrorPolicyTypeFromString(tmp)) <= 0) {
|
||||
if ((tmp = virXMLPropString(cur, "error_policy"))) {
|
||||
int error_policy;
|
||||
|
||||
if ((error_policy = virDomainDiskErrorPolicyTypeFromString(tmp)) <= 0) {
|
||||
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
|
||||
_("unknown disk error policy '%s'"), tmp);
|
||||
return -1;
|
||||
}
|
||||
def->error_policy = error_policy;
|
||||
}
|
||||
VIR_FREE(tmp);
|
||||
|
||||
if ((tmp = virXMLPropString(cur, "rerror_policy")) &&
|
||||
|
@ -567,7 +567,7 @@ struct _virDomainDiskDef {
|
||||
char *vendor;
|
||||
char *product;
|
||||
virDomainDiskCache cachemode;
|
||||
int error_policy; /* enum virDomainDiskErrorPolicy */
|
||||
virDomainDiskErrorPolicy error_policy;
|
||||
int rerror_policy; /* enum virDomainDiskErrorPolicy */
|
||||
int iomode; /* enum virDomainDiskIo */
|
||||
virTristateSwitch ioeventfd;
|
||||
|
Loading…
x
Reference in New Issue
Block a user