diff mbox

[20/28] libxl: domcreate_dm_support_checked: Introduce `goto out'

Message ID 1450809903-3393-21-git-send-email-ian.jackson@eu.citrix.com (mailing list archive)
State New, archived
Headers show

Commit Message

Ian Jackson Dec. 22, 2015, 6:44 p.m. UTC
We are going to want this shortly.

No functional change.

Signed-off-by: Ian Jackson <Ian.Jackson@eu.citrix.com>
---
v6: New patch.
---
 tools/libxl/libxl_create.c |    9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)
diff mbox

Patch

diff --git a/tools/libxl/libxl_create.c b/tools/libxl/libxl_create.c
index 71893c5..b41c6bd 100644
--- a/tools/libxl/libxl_create.c
+++ b/tools/libxl/libxl_create.c
@@ -968,10 +968,7 @@  static void domcreate_dm_support_checked(libxl__egc *egc,
     libxl_domain_config *const d_config = dcs->guest_config;
     const int restore_fd = dcs->restore_fd;
 
-    if (rc) {
-        domcreate_complete(egc, dcs, rc);
-        return;
-    }
+    if (rc) goto out;
 
     dcs->bl.ao = ao;
     libxl_device_disk *bootdisk =
@@ -994,6 +991,10 @@  static void domcreate_dm_support_checked(libxl__egc *egc,
         libxl__bootloader_run(egc, &dcs->bl);
     }
     return;
+
+ out:
+    domcreate_complete(egc, dcs, rc);
+    return;
 }
 
 static void domcreate_bootloader_console_available(libxl__egc *egc,