# HG changeset patch # User Richard M. Stallman # Date 867824700 0 # Node ID 488df9d19f5e10179875377e7d23d5204dc9de80 # Parent 35a263e545b39722abee918a1a0311cd872cab94 (re_search_2): Cast result of POS_ADDR_VSTRING. diff -r 35a263e545b3 -r 488df9d19f5e src/regex.c --- a/src/regex.c Wed Jul 02 06:23:21 1997 +0000 +++ b/src/regex.c Wed Jul 02 06:25:00 1997 +0000 @@ -3856,8 +3856,10 @@ /* Update STARTPOS to the next character boundary. */ if (multibyte) { - const unsigned char *p = POS_ADDR_VSTRING (startpos); - const unsigned char *pend = STOP_ADDR_VSTRING (startpos); + const unsigned char *p + = (const unsigned char *) POS_ADDR_VSTRING (startpos); + const unsigned char *pend + = (const unsigned char *) STOP_ADDR_VSTRING (startpos); int len = MULTIBYTE_FORM_LENGTH (p, pend - p); range -= len; @@ -3867,9 +3869,9 @@ } else { - range--; - startpos++; - } + range--; + startpos++; + } } else { @@ -3879,7 +3881,8 @@ /* Update STARTPOS to the previous character boundary. */ if (multibyte) { - const unsigned char *p = POS_ADDR_VSTRING (startpos); + const unsigned char *p + = (const unsigned char *) POS_ADDR_VSTRING (startpos); int len = 0; /* Find the head of multibyte form. */