Fbackward_prefix_chars: stay within buffer bounds
commitb49cb0ab9c165c1e861b5dfac5eb7ef6cb9e4e3a
authorNoam Postavsky <npostavs@gmail.com>
Sat, 4 Jun 2016 13:02:20 +0000 (4 09:02 -0400)
committerNoam Postavsky <npostavs@gmail.com>
Fri, 17 Jun 2016 03:18:00 +0000 (16 23:18 -0400)
tree03215f5a43d7156e8aded110970158da5255ce01
parentd765175ef1179f834c25fd856ace63c3dc37162c
Fbackward_prefix_chars: stay within buffer bounds

The commit 1fd3172d "(Fbackward_prefix_chars): Set point properly while
scanning" (1998-03-18), moved the check against of the position against the
buffer beginning out the loop condition so that we might end up checking
the syntax of characters before the beginning of the buffer.  This can
cause segfaults or trigger a "Point before start of properties" error in
`update_interval' (called indirectly from `char_quoted').

* src/syntax.c (Fbackward_prefix_chars): Stop the loop when beginning of
buffer is reached (Bug #3552, Bug #17132, Bug #19379).
src/syntax.c