SF.net SVN: geany:[2856] trunk
eht16 at users.sourceforge.net
eht16 at xxxxx
Tue Aug 5 08:54:02 UTC 2008
Revision: 2856
http://geany.svn.sourceforge.net/geany/?rev=2856&view=rev
Author: eht16
Date: 2008-08-05 08:54:02 +0000 (Tue, 05 Aug 2008)
Log Message:
-----------
Fix wrong parsing of keywords if they are not followed by a space (closes #2037728).
Modified Paths:
--------------
trunk/ChangeLog
trunk/tagmanager/tcl.c
Modified: trunk/ChangeLog
===================================================================
--- trunk/ChangeLog 2008-08-05 08:52:59 UTC (rev 2855)
+++ trunk/ChangeLog 2008-08-05 08:54:02 UTC (rev 2856)
@@ -3,6 +3,9 @@
* src/vte.c:
Revert the recent VTE realisation changes as they don't make things
better.
+ * tagmanager/tcl.c:
+ Fix wrong parsing of keywords if they are not followed by a space
+ (closes #2037728).
2008-08-03 Enrico Tröger <enrico(dot)troeger(at)uvena(dot)de>
Modified: trunk/tagmanager/tcl.c
===================================================================
--- trunk/tagmanager/tcl.c 2008-08-05 08:52:59 UTC (rev 2855)
+++ trunk/tagmanager/tcl.c 2008-08-05 08:54:02 UTC (rev 2856)
@@ -55,7 +55,16 @@
static boolean match (const unsigned char *line, const char *word)
{
- return (boolean) (strncmp ((const char*) line, word, strlen (word)) == 0);
+ size_t len = strlen (word);
+ boolean matched = (strncmp ((const char*) line, word, len) == 0);
+
+ if (matched)
+ {
+ /* check that the word is followed by a space to avoid detecting something
+ * like "proc_new ..." */
+ matched = isspace (*(line + len));
+ }
+ return matched;
}
static void findTclTags (void)
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the Commits
mailing list