Fix syntax scanning bug causing fontification crashes.

* src/syntax.c (find_defun_start): Update all cache variables if
exiting early.

Fixes: debbugs:9401
This commit is contained in:
Chong Yidong 2011-08-30 18:38:07 -04:00
parent 1f403cb991
commit 6e20a0d47c
2 changed files with 10 additions and 0 deletions

View file

@ -1,3 +1,8 @@
2011-08-30 Chong Yidong <cyd@stupidchicken.com>
* syntax.c (find_defun_start): Update all cache variables if
exiting early (Bug#9401).
2011-08-19 Andreas Schwab <schwab@linux-m68k.org>
* keyboard.c: Include "process.h"

View file

@ -364,7 +364,12 @@ find_defun_start (pos, pos_byte)
if (!open_paren_in_column_0_is_defun_start)
{
find_start_value = BEGV;
find_start_value_byte = BEGV_BYTE;
find_start_buffer = current_buffer;
find_start_modiff = MODIFF;
find_start_begv = BEGV;
find_start_pos = pos;
return BEGV;
}