From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LfyzU-0006GL-Bz for qemu-devel@nongnu.org; Sat, 07 Mar 2009 11:03:08 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1LfyzT-0006EQ-OG for qemu-devel@nongnu.org; Sat, 07 Mar 2009 11:03:07 -0500 Received: from [199.232.76.173] (port=33131 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LfyzT-0006EE-6q for qemu-devel@nongnu.org; Sat, 07 Mar 2009 11:03:07 -0500 Received: from savannah.gnu.org ([199.232.41.3]:58265 helo=sv.gnu.org) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1LfyzS-0004aK-NV for qemu-devel@nongnu.org; Sat, 07 Mar 2009 11:03:06 -0500 Received: from cvs.savannah.gnu.org ([199.232.41.69]) by sv.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1LfyzS-0000En-DT for qemu-devel@nongnu.org; Sat, 07 Mar 2009 16:03:06 +0000 Received: from blueswir1 by cvs.savannah.gnu.org with local (Exim 4.69) (envelope-from ) id 1LfyzS-0000Eh-6s for qemu-devel@nongnu.org; Sat, 07 Mar 2009 16:03:06 +0000 MIME-Version: 1.0 Errors-To: blueswir1 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit From: Blue Swirl Message-Id: Date: Sat, 07 Mar 2009 16:03:06 +0000 Subject: [Qemu-devel] [6741] Sparse fixes: dubious mixing of bitwise and logical operations Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Revision: 6741 http://svn.sv.gnu.org/viewvc/?view=rev&root=qemu&revision=6741 Author: blueswir1 Date: 2009-03-07 16:03:05 +0000 (Sat, 07 Mar 2009) Log Message: ----------- Sparse fixes: dubious mixing of bitwise and logical operations Modified Paths: -------------- trunk/fpu/softfloat-specialize.h trunk/hw/cirrus_vga.c Modified: trunk/fpu/softfloat-specialize.h =================================================================== --- trunk/fpu/softfloat-specialize.h 2009-03-07 15:59:09 UTC (rev 6740) +++ trunk/fpu/softfloat-specialize.h 2009-03-07 16:03:05 UTC (rev 6741) @@ -166,7 +166,7 @@ res = bIsNaN ? bv : av; } else if ( aIsNaN ) { - if ( bIsSignalingNaN | ! bIsNaN ) + if ( bIsSignalingNaN || ! bIsNaN ) res = av; else { returnLargerSignificand: @@ -301,7 +301,7 @@ res = bIsNaN ? bv : av; } else if ( aIsNaN ) { - if ( bIsSignalingNaN | ! bIsNaN ) + if ( bIsSignalingNaN || ! bIsNaN ) res = av; else { returnLargerSignificand: @@ -441,7 +441,7 @@ return bIsNaN ? b : a; } else if ( aIsNaN ) { - if ( bIsSignalingNaN | ! bIsNaN ) return a; + if ( bIsSignalingNaN || ! bIsNaN ) return a; returnLargerSignificand: if ( a.low < b.low ) return b; if ( b.low < a.low ) return a; @@ -567,7 +567,7 @@ return bIsNaN ? b : a; } else if ( aIsNaN ) { - if ( bIsSignalingNaN | ! bIsNaN ) return a; + if ( bIsSignalingNaN || ! bIsNaN ) return a; returnLargerSignificand: if ( lt128( a.high<<1, a.low, b.high<<1, b.low ) ) return b; if ( lt128( b.high<<1, b.low, a.high<<1, a.low ) ) return a; Modified: trunk/hw/cirrus_vga.c =================================================================== --- trunk/hw/cirrus_vga.c 2009-03-07 15:59:09 UTC (rev 6740) +++ trunk/hw/cirrus_vga.c 2009-03-07 16:03:05 UTC (rev 6741) @@ -2246,7 +2246,7 @@ CirrusVGAState *s = (CirrusVGAState *)s1; int size; - if (!s->sr[0x12] & CIRRUS_CURSOR_SHOW) { + if (!(s->sr[0x12] & CIRRUS_CURSOR_SHOW)) { size = 0; } else { if (s->sr[0x12] & CIRRUS_CURSOR_LARGE)