From 80e0e92aaa620acae14e46a2b63f01cb29f21602 Mon Sep 17 00:00:00 2001 From: Fred Fish Date: Tue, 30 Jul 1996 06:15:13 +0000 Subject: * mips-tdep.c (mips_read_processor_type): Add parens around bitwise-and operands in comparison; previous expression always evaluated to 0 because of equality comparison of two constants. --- gdb/ChangeLog | 4 ++++ gdb/mips-tdep.c | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) (limited to 'gdb') diff --git a/gdb/ChangeLog b/gdb/ChangeLog index d60d61e..f901c0c 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,5 +1,9 @@ Mon Jul 29 21:13:20 1996 Fred Fish + * mips-tdep.c (mips_read_processor_type): Add parens around + bitwise-and operands in comparison; previous expression always + evaluated to 0 because of equality comparison of two constants. + * rs6000-tdep.c (skip_prologue): Add missing parens around operands of logical-or so that first operand does not bind to previous logical-and. diff --git a/gdb/mips-tdep.c b/gdb/mips-tdep.c index 427e0f6..6a37d1a 100644 --- a/gdb/mips-tdep.c +++ b/gdb/mips-tdep.c @@ -1505,7 +1505,7 @@ mips_read_processor_type () prid = read_register (PRID_REGNUM); - if (prid & ~0xf == 0x700) + if ((prid & ~0xf) == 0x700) return savestring ("r3041", strlen("r3041")); return NULL; -- cgit v1.1