a41c76
From 92ec9a02d57b18eac3abc33e0807cd70c6bb46c5 Mon Sep 17 00:00:00 2001
a41c76
Message-Id: <92ec9a02d57b18eac3abc33e0807cd70c6bb46c5@dist-git>
a41c76
From: Peter Krempa <pkrempa@redhat.com>
a41c76
Date: Tue, 4 Feb 2020 15:08:03 +0100
a41c76
Subject: [PATCH] qemuMigrationCookieNBD: Extract embedded struct
a41c76
MIME-Version: 1.0
a41c76
Content-Type: text/plain; charset=UTF-8
a41c76
Content-Transfer-Encoding: 8bit
a41c76
a41c76
Extract the struct so that it's type has a name.
a41c76
a41c76
Signed-off-by: Peter Krempa <pkrempa@redhat.com>
a41c76
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
a41c76
(cherry picked from commit 3093822d1d8e3bbd01ea59f35a9fea1228f9268f)
a41c76
a41c76
https://bugzilla.redhat.com/show_bug.cgi?id=1793263
a41c76
Message-Id: <e05be367f0869dbbf726cea7e91925fc48bb683f.1580824112.git.pkrempa@redhat.com>
a41c76
Reviewed-by: Ján Tomko <jtomko@redhat.com>
a41c76
---
a41c76
 src/qemu/qemu_migration_cookie.h | 10 ++++++----
a41c76
 1 file changed, 6 insertions(+), 4 deletions(-)
a41c76
a41c76
diff --git a/src/qemu/qemu_migration_cookie.h b/src/qemu/qemu_migration_cookie.h
a41c76
index 20e1ed60ca..1e88684589 100644
a41c76
--- a/src/qemu/qemu_migration_cookie.h
a41c76
+++ b/src/qemu/qemu_migration_cookie.h
a41c76
@@ -84,16 +84,18 @@ struct _qemuMigrationCookieNetwork {
a41c76
     qemuMigrationCookieNetDataPtr net;
a41c76
 };
a41c76
 
a41c76
+struct qemuMigrationCookieNBDDisk {
a41c76
+    char *target;                   /* Disk target */
a41c76
+    unsigned long long capacity;    /* And its capacity */
a41c76
+};
a41c76
+
a41c76
 typedef struct _qemuMigrationCookieNBD qemuMigrationCookieNBD;
a41c76
 typedef qemuMigrationCookieNBD *qemuMigrationCookieNBDPtr;
a41c76
 struct _qemuMigrationCookieNBD {
a41c76
     int port; /* on which port does NBD server listen for incoming data */
a41c76
 
a41c76
     size_t ndisks;  /* Number of items in @disk array */
a41c76
-    struct {
a41c76
-        char *target;                   /* Disk target */
a41c76
-        unsigned long long capacity;    /* And its capacity */
a41c76
-    } *disks;
a41c76
+    struct qemuMigrationCookieNBDDisk *disks;
a41c76
 };
a41c76
 
a41c76
 typedef struct _qemuMigrationCookieCaps qemuMigrationCookieCaps;
a41c76
-- 
a41c76
2.25.0
a41c76