This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
ubsan: hppa: negation of -2147483648
- From: Alan Modra <amodra at gmail dot com>
- To: binutils at sourceware dot org
- Date: Mon, 20 Jan 2020 20:21:21 +1030
- Subject: ubsan: hppa: negation of -2147483648
* hppa-dis.c (fput_const): Remove useless cast.
diff --git a/opcodes/hppa-dis.c b/opcodes/hppa-dis.c
index 3c15701716..93156da7cb 100644
--- a/opcodes/hppa-dis.c
+++ b/opcodes/hppa-dis.c
@@ -207,7 +207,7 @@ static void
fput_const (unsigned num, disassemble_info *info)
{
if ((int) num < 0)
- (*info->fprintf_func) (info->stream, "-%x", - (int) num);
+ (*info->fprintf_func) (info->stream, "-%x", -num);
else
(*info->fprintf_func) (info->stream, "%x", num);
}
--
Alan Modra
Australia Development Lab, IBM