(Fbyte_code): For relative gotos, force signed arithmetic.
authorRichard M. Stallman <rms@gnu.org>
Fri, 16 Aug 1996 19:08:24 +0000 (19:08 +0000)
committerRichard M. Stallman <rms@gnu.org>
Fri, 16 Aug 1996 19:08:24 +0000 (19:08 +0000)
src/bytecode.c

index 3221970..4fb6d86 100644 (file)
@@ -475,14 +475,14 @@ If the third argument is incorrect, Emacs may crash.")
 
        case BRgoto:
          QUIT;
-         pc += *pc - 127;
+         pc += (int) *pc - 127;
          break;
 
        case BRgotoifnil:
          if (NILP (POP))
            {
              QUIT;
-             pc += *pc - 128;
+             pc += (int) *pc - 128;
            }
          pc++;
          break;
@@ -491,7 +491,7 @@ If the third argument is incorrect, Emacs may crash.")
          if (!NILP (POP))
            {
              QUIT;
-             pc += *pc - 128;
+             pc += (int) *pc - 128;
            }
          pc++;
          break;