From: Gunther Nikl Date: Thu, 2 Apr 2020 07:57:45 +0000 (+0100) Subject: [PATCH gas/m68k] Fix a register range check X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=59e28a9767bf237951839204ebc3e412bc27a175;p=binutils-gdb.git [PATCH gas/m68k] Fix a register range check * config/tc-m68k.c (m68k_ip): Fix range check for index register with a suppressed address register. --- diff --git a/gas/ChangeLog b/gas/ChangeLog index ef0217e5d70..83108d362c2 100644 --- a/gas/ChangeLog +++ b/gas/ChangeLog @@ -1,3 +1,8 @@ +2020-04-02 Gunther Nikl + + * config/tc-m68k.c (m68k_ip): Fix range check for index register + with a suppressed address register. + 2020-04-01 H.J. Lu PR gas/25756 diff --git a/gas/config/tc-m68k.c b/gas/config/tc-m68k.c index 5483f8e017a..490df5dbf5f 100644 --- a/gas/config/tc-m68k.c +++ b/gas/config/tc-m68k.c @@ -2794,7 +2794,7 @@ m68k_ip (char *instring) && opP->index.reg <= ZDATA7) nextword |= (opP->index.reg - ZDATA0) << 12; else if (opP->index.reg >= ZADDR0 - || opP->index.reg <= ZADDR7) + && opP->index.reg <= ZADDR7) nextword |= (opP->index.reg - ZADDR0 + 8) << 12; }