Olaf Hering
2010-Nov-02 22:37 UTC
[Xen-devel] [PATCH] qemu-xen: fix compiler warning in load_linux
fix compile warning. /usr/src/packages/BUILD/xen-unstable.hg-4.1.21864/tools/ioemu-dir/hw/pc.c: In function ''load_linux'': /usr/src/packages/BUILD/xen-unstable.hg-4.1.21864/tools/ioemu-dir/hw/pc.c:713:39: warning: operation on ''seg[4]'' may be undefined Signed-off-by: Olaf Hering <olaf@aepfle.de> --- ioemu-remote/hw/pc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- xen-unstable.hg-4.1.22241.orig/ioemu-remote/hw/pc.c +++ xen-unstable.hg-4.1.22241/ioemu-remote/hw/pc.c @@ -714,7 +714,7 @@ static void load_linux(uint8_t *option_r /* generate bootsector to set up the initial register state */ real_seg = real_addr >> 4; - seg[0] = seg[2] = seg[3] = seg[4] = seg[4] = real_seg; + seg[0] = seg[2] = seg[3] = seg[4] = real_seg; seg[1] = real_seg+0x20; /* CS */ memset(gpr, 0, sizeof gpr); gpr[4] = cmdline_addr-real_addr-16; /* SP (-16 is paranoia) */ _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel