From: Chen Gang Date: Tue, 11 Nov 2014 09:23:40 +0000 (+0800) Subject: xen-hvm: Remove redundant variable 'xstate' X-Git-Tag: qemu-xen-4.6.0-rc1~79^2~3 X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=d208a85f1568ab8aec238cb91367581c61350008;p=qemu-upstream-4.6-testing.git xen-hvm: Remove redundant variable 'xstate' In xen_hvm_change_state_handler(), we can pass 'opaque' with type cast to xen_main_loop_prepare() directly, there's no need to use additional variable for it. Signed-off-by: Chen Gang Acked-by: Stefano Stabellini Signed-off-by: Michael Tokarev --- diff --git a/xen-hvm.c b/xen-hvm.c index 21f1cbb01..754879481 100644 --- a/xen-hvm.c +++ b/xen-hvm.c @@ -993,9 +993,8 @@ static void xen_main_loop_prepare(XenIOState *state) static void xen_hvm_change_state_handler(void *opaque, int running, RunState rstate) { - XenIOState *xstate = opaque; if (running) { - xen_main_loop_prepare(xstate); + xen_main_loop_prepare((XenIOState *)opaque); } }