aboutsummaryrefslogtreecommitdiff
path: root/opcodes
diff options
context:
space:
mode:
Diffstat (limited to 'opcodes')
-rw-r--r--opcodes/cris-dis.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/opcodes/cris-dis.c b/opcodes/cris-dis.c
index b8eaa4b..681fccf 100644
--- a/opcodes/cris-dis.c
+++ b/opcodes/cris-dis.c
@@ -580,12 +580,7 @@ static char *
format_dec (long number, char *outbuffer, int signedp)
{
last_immediate = number;
- if (signedp)
- sprintf (outbuffer, "%ld", number);
- else
- sprintf (outbuffer, "%lu", (unsigned long) number);
-
- return outbuffer + strlen (outbuffer);
+ return outbuffer + sprintf (outbuffer, signedp ? "%ld" : "%lu", number);
}
/* Format the name of the general register regno into outbuffer. */