This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH] gdb/hppa-tdep.c: Fix a logical typo bug found by compiler warning
- From: Andreas Schwab <schwab at linux-m68k dot org>
- To: Chen Gang <gang dot chen dot 5i5j at gmail dot com>
- Cc: Joel Brobecker <brobecker at adacore dot com>, gdb-patches at sourceware dot org
- Date: Thu, 16 Oct 2014 09:06:43 +0200
- Subject: Re: [PATCH] gdb/hppa-tdep.c: Fix a logical typo bug found by compiler warning
- Authentication-results: sourceware.org; auth=none
- References: <d6q0acpdxmm7g52oqylkjjb2 dot 1413419448973 at email dot android dot com>
There's another bug in this function:
/* Does it look like a stw? */
if ((inst >> 26) == 0x1a || (inst >> 26) == 0x1b
|| (inst >> 26) == 0x1f
|| ((inst >> 26) == 0x1f
&& ((inst >> 6) == 0xa)))
return hppa_extract_5R_store (inst);
The last condition is redundant.
Andreas.
--
Andreas Schwab, SUSE Labs, schwab@suse.de
GPG Key fingerprint = 0196 BAD8 1CE9 1970 F4BE 1748 E4D4 88E3 0EEA B9D7
"And now for something completely different."