[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Bug binutils/20657] buglet in putop() in opcodes/i386-dis.c
From: |
hjl.tools at gmail dot com |
Subject: |
[Bug binutils/20657] buglet in putop() in opcodes/i386-dis.c |
Date: |
Fri, 30 Sep 2016 15:52:26 +0000 |
https://sourceware.org/bugzilla/show_bug.cgi?id=20657
H.J. Lu <hjl.tools at gmail dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Assignee|unassigned at sourceware dot org |hjl.tools at gmail dot
com
--- Comment #1 from H.J. Lu <hjl.tools at gmail dot com> ---
The change from:
https://sourceware.org/ml/binutils/2007-09/msg00413.html
@@ -5695,24 +5867,10 @@ putop (const char *template, int sizefla
case '{':
alt = 0;
if (intel_syntax)
- alt += 1;
- if (address_mode == mode_64bit)
- alt += 2;
- while (alt != 0)
{
while (*++p != '|')
- {
- if (*p == '}')
- {
- /* Alternative not valid. */
- strcpy (obuf, "(bad)");
- obufp = obuf + 5;
- return 1;
- }
- else if (*p == '\0')
- abort ();
- }
- alt--;
+ if (*p == '}' || *p == '\0')
+ abort ();
}
/* Fall through. */
case 'I':
should also remove "alt = 0".
--
You are receiving this mail because:
You are on the CC list for the bug.