[PATCH 16/17] Fix broken formatting on OOM in xenFormatXM

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: "Daniel P. Berrange" <berrange@xxxxxxxxxx>

If an OOM occurs when xenFormatXM is setting the 'hpet'
variable it is silently ignored. Fix it to propagate
to the callers.

Signed-off-by: Daniel P. Berrange <berrange@xxxxxxxxxx>
---
 src/xenxs/xen_xm.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/xenxs/xen_xm.c b/src/xenxs/xen_xm.c
index 1652fff..7550a07 100644
--- a/src/xenxs/xen_xm.c
+++ b/src/xenxs/xen_xm.c
@@ -1601,7 +1601,7 @@ virConfPtr xenFormatXM(virConnectPtr conn,
             if (def->clock.timers[i]->name == VIR_DOMAIN_TIMER_NAME_HPET &&
                 def->clock.timers[i]->present != -1 &&
                 xenXMConfigSetInt(conf, "hpet", def->clock.timers[i]->present) < 0)
-                    break;
+                goto cleanup;
         }
 
         if (xendConfigVersion == XEND_CONFIG_VERSION_3_0_2) {
-- 
1.8.3.1

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]