]> xenbits.xensource.com Git - qemu-xen.git/commitdiff
target-alpha: fix uninitialized variable
authorPaolo Bonzini <pbonzini@redhat.com>
Mon, 19 Oct 2015 14:08:38 +0000 (16:08 +0200)
committerMichael Tokarev <mjt@tls.msk.ru>
Fri, 6 Nov 2015 12:42:38 +0000 (15:42 +0300)
I am not sure why the compiler does not catch it.  There is no
semantic change since gen_excp returns EXIT_NORETURN, but the
old code is wrong.

Reported by Coverity.

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
target-alpha/translate.c

index 87950c63ecde416b3cc8a2035fc46255a4095dfd..9909c70b1bb2140ae704ff58dc78b7f938156e9b 100644 (file)
@@ -2916,7 +2916,7 @@ void gen_intermediate_code(CPUAlphaState *env, struct TranslationBlock *tb)
         num_insns++;
 
         if (unlikely(cpu_breakpoint_test(cs, ctx.pc, BP_ANY))) {
-            gen_excp(&ctx, EXCP_DEBUG, 0);
+            ret = gen_excp(&ctx, EXCP_DEBUG, 0);
             /* The address covered by the breakpoint must be included in
                [tb->pc, tb->pc + tb->size) in order to for it to be
                properly cleared -- thus we increment the PC here so that