# HG changeset patch # User Chong Yidong # Date 1266675080 18000 # Node ID 5cec35cc882b3d205e8e2b05c06e4785fc7160da # Parent 5e6600997bb8c62fd6126185c7adb4677363f912 * etags.c (Scheme_functions): Don't loop past a null character (Bug#5601). diff -r 5e6600997bb8 -r 5cec35cc882b lib-src/ChangeLog --- a/lib-src/ChangeLog Sat Feb 20 08:53:06 2010 -0500 +++ b/lib-src/ChangeLog Sat Feb 20 09:11:20 2010 -0500 @@ -1,3 +1,8 @@ +2010-02-20 Kevin Ryde + + * etags.c (Scheme_functions): Don't loop past a null character + (Bug#5601). + 2010-01-29 Kester Habermann (tiny change) * etags.c (Fortran_functions): Handle recursive keyword diff -r 5e6600997bb8 -r 5cec35cc882b lib-src/etags.c --- a/lib-src/etags.c Sat Feb 20 08:53:06 2010 -0500 +++ b/lib-src/etags.c Sat Feb 20 09:11:20 2010 -0500 @@ -5004,8 +5004,9 @@ if (strneq (bp, "(def", 4) || strneq (bp, "(DEF", 4)) { bp = skip_non_spaces (bp+4); - /* Skip over open parens and white space */ - while (notinname (*bp)) + /* Skip over open parens and white space. Don't continue past + '\0'. */ + while (*bp && notinname (*bp)) bp++; get_tag (bp, NULL); }