Commit 02ba9265 authored by Jeff Cody's avatar Jeff Cody Committed by Peter Maydell
Browse files

migration: fix compiler warning on uninitialized variable



Some older GCC versions (e.g. 4.4.7) report a warning on an
uninitialized variable for 'request', even though all possible code
paths that reference 'request' will be initialized.   To appease
these versions, initialize the variable to 0.

Reported-by: default avatarMark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
Signed-off-by: default avatarJeff Cody <jcody@redhat.com>
Reviewed-by: default avatarzhanghailiang <zhang.zhanghailiang@huawei.com>
Message-id: 259818682e41b95ae60f1423b87954a3fe377639.1477950393.git.jcody@redhat.com
Signed-off-by: default avatarPeter Maydell <peter.maydell@linaro.org>
parent b90da81d
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -439,7 +439,7 @@ void *colo_process_incoming_thread(void *opaque)
    }

    while (mis->state == MIGRATION_STATUS_COLO) {
        int request;
        int request = 0;

        colo_wait_handle_message(mis->from_src_file, &request, &local_err);
        if (local_err) {