changeset 20297:19c4eb4c448d

Sat May 11 13:30:53 1996 enami tsugutomo <enami@ba2.so-net.or.jp> * regex.c (re_match_2_internal): Fix off-by-one error; don't use length of exactn as character, and don't use length of bitmap of charset as bitmap.
author Jim Meyering <jim@meyering.net>
date Sun, 12 May 1996 02:57:30 +0000
parents eec9d842372b
children 12c63b73ba4a
files lib/regex.c
diffstat 1 files changed, 3 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/lib/regex.c	Sat May 11 18:05:52 1996 +0000
+++ b/lib/regex.c	Sun May 12 02:57:30 1996 +0000
@@ -4505,9 +4505,9 @@
 #endif
 
                 if ((re_opcode_t) p1[3] == exactn
-		    && ! ((int) p2[1] * BYTEWIDTH > (int) p1[4]
-			  && (p2[1 + p1[4] / BYTEWIDTH]
-			      & (1 << (p1[4] % BYTEWIDTH)))))
+		    && ! ((int) p2[1] * BYTEWIDTH > (int) p1[5]
+			  && (p2[2 + p1[5] / BYTEWIDTH]
+			      & (1 << (p1[5] % BYTEWIDTH)))))
                   {
   		    p[-3] = (unsigned char) pop_failure_jump;
                     DEBUG_PRINT3 ("  %c != %c => pop_failure_jump.\n",