]> Git Repo - qemu.git/commitdiff
Add missing check for host_from_stream_offset return value for RAM_SAVE_FLAG_PAGE
authorOrit Wasserman <[email protected]>
Tue, 19 Jun 2012 08:51:37 +0000 (11:51 +0300)
committerJuan Quintela <[email protected]>
Fri, 29 Jun 2012 08:38:28 +0000 (10:38 +0200)
Signed-off-by: Orit Wasserman <[email protected]>
arch_init.c

index a9e8b7442be112afeebc6f32b92d471048a26a84..81c2e5443f9cff6524dc8d475fa6bbfd1a581d30 100644 (file)
@@ -483,6 +483,9 @@ int ram_load(QEMUFile *f, void *opaque, int version_id)
             void *host;
 
             host = host_from_stream_offset(f, addr, flags);
+            if (!host) {
+                return -EINVAL;
+            }
 
             qemu_get_buffer(f, host, TARGET_PAGE_SIZE);
         }
This page took 0.027845 seconds and 4 git commands to generate.