arch_init: Clean up the duplicate variable 'len' defining in ram_load()
authorzhanghailiang <zhang.zhanghailiang@huawei.com>
Fri, 15 May 2015 09:00:03 +0000 (17:00 +0800)
committerJuan Quintela <quintela@redhat.com>
Fri, 12 Jun 2015 04:42:34 +0000 (06:42 +0200)
There are two places that define 'len' variable, It's OK for compiling,
but makes it difficult for reading.

Remove the local one which defined in the inside 'while' loop.

Signed-off-by: zhanghailiang <zhang.zhanghailiang@huawei.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>
migration/ram.c

index 394532860906d23a4295d2be0e294c547bac80e4..57368e15757da808b96322ddf6d57e8904b5a430 100644 (file)
@@ -1459,7 +1459,6 @@ static int ram_load(QEMUFile *f, void *opaque, int version_id)
             total_ram_bytes = addr;
             while (!ret && total_ram_bytes) {
                 RAMBlock *block;
-                uint8_t len;
                 char id[256];
                 ram_addr_t length;