aboutsummaryrefslogtreecommitdiff
path: root/opcodes/cris-dis.c
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2005-02-24 13:38:01 +0000
committerAlan Modra <amodra@gmail.com>2005-02-24 13:38:01 +0000
commit47d8304e8837825ab4fd60922b28f30c623f2c02 (patch)
tree1bab33d0bd25db1f298726002d5748ef074861c5 /opcodes/cris-dis.c
parentb2d52a4828c7bc73e3691c7620ce917f1c862d89 (diff)
downloadgdb-47d8304e8837825ab4fd60922b28f30c623f2c02.zip
gdb-47d8304e8837825ab4fd60922b28f30c623f2c02.tar.gz
gdb-47d8304e8837825ab4fd60922b28f30c623f2c02.tar.bz2
* cris-dis.c (format_hex): Remove ineffective warning fix.
* crx-dis.c (make_instruction): Warning fix. * frv-asm.c: Regenerate.
Diffstat (limited to 'opcodes/cris-dis.c')
-rw-r--r--opcodes/cris-dis.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/opcodes/cris-dis.c b/opcodes/cris-dis.c
index 372f085..b6b7559 100644
--- a/opcodes/cris-dis.c
+++ b/opcodes/cris-dis.c
@@ -448,10 +448,8 @@ format_hex (number, outbuffer, disdata)
char *outbuffer;
struct cris_disasm_data *disdata;
{
- /* Obfuscate to avoid warning on 32-bit host, but properly truncate
- negative numbers on >32-bit hosts. */
- if (sizeof (number) > 4)
- number &= (1 << (sizeof (number) > 4 ? 32 : 1)) - 1;
+ /* Truncate negative numbers on >32-bit hosts. */
+ number &= 0xffffffff;
sprintf (outbuffer, "0x%lx", number);