[PATCH 3/4] hyperv: Drop needles error label in hypervCreateEmbeddedParam()

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

 



Signed-off-by: Michal Privoznik <mprivozn@xxxxxxxxxx>
---
 src/hyperv/hyperv_wmi.c | 9 +++------
 1 file changed, 3 insertions(+), 6 deletions(-)

diff --git a/src/hyperv/hyperv_wmi.c b/src/hyperv/hyperv_wmi.c
index 2faa2f396f..489bb03a9b 100644
--- a/src/hyperv/hyperv_wmi.c
+++ b/src/hyperv/hyperv_wmi.c
@@ -325,7 +325,7 @@ hypervCreateEmbeddedParam(hypervPrivate *priv, hypervWmiClassInfoListPtr info)
 
     /* Get the typeinfo out of the class info list */
     if (hypervGetWmiClassInfo(priv, info, &classInfo) < 0)
-        goto error;
+        return NULL;
 
     typeinfo = classInfo->serializerInfo;
 
@@ -335,19 +335,16 @@ hypervCreateEmbeddedParam(hypervPrivate *priv, hypervWmiClassInfoListPtr info)
 
     table = virHashCreate(count, NULL);
     if (table == NULL)
-        goto error;
+        return NULL;
 
     for (i = 0; typeinfo[i].name != NULL; i++) {
         item = &typeinfo[i];
 
         if (virHashAddEntry(table, item->name, NULL) < 0)
-            goto error;
+            return NULL;
     }
 
     return g_steal_pointer(&table);
-
- error:
-    return NULL;
 }
 
 
-- 
2.26.2




[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]

  Powered by Linux