]> git.proxmox.com Git - qemu.git/commitdiff
migration: Fix compiler warning ('caps' may be used uninitialized)
authorMichael Tokarev <mjt@tls.msk.ru>
Sat, 5 Oct 2013 09:18:28 +0000 (13:18 +0400)
committerMichael Tokarev <mjt@tls.msk.ru>
Sat, 5 Oct 2013 10:02:29 +0000 (14:02 +0400)
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
Reviewed-by: Stefan Weil <sw@weilnetz.de>
migration.c

index b4f8462ae475fe1958d2da995fb8eaa2eeaca559..2b1ab20c54f9e93630dd85102a1c8466058fdc6a 100644 (file)
@@ -150,6 +150,7 @@ MigrationCapabilityStatusList *qmp_query_migrate_capabilities(Error **errp)
     MigrationState *s = migrate_get_current();
     int i;
 
+    caps = NULL; /* silence compiler warning */
     for (i = 0; i < MIGRATION_CAPABILITY_MAX; i++) {
         if (head == NULL) {
             head = g_malloc0(sizeof(*caps));