SF.net SVN: geany: [950] trunk
ntrel at users.sourceforge.net
ntrel at xxxxx
Wed Nov 1 10:58:56 UTC 2006
Revision: 950
http://svn.sourceforge.net/geany/?rev=950&view=rev
Author: ntrel
Date: 2006-11-01 02:58:47 -0800 (Wed, 01 Nov 2006)
Log Message:
-----------
Prevent possible invalid memory read.
Modified Paths:
--------------
trunk/ChangeLog
trunk/src/document.c
Modified: trunk/ChangeLog
===================================================================
--- trunk/ChangeLog 2006-10-30 23:00:26 UTC (rev 949)
+++ trunk/ChangeLog 2006-11-01 10:58:47 UTC (rev 950)
@@ -1,3 +1,8 @@
+2006-11-01 Nick Treleaven <nick.treleaven at btinternet.com>
+
+ * src/document.c: Prevent possible invalid memory read.
+
+
2006-10-30 Enrico Tröger <enrico.troeger at uvena.de>
* src/sci_cb.c: Add extra indentation for Python after a colon.
Modified: trunk/src/document.c
===================================================================
--- trunk/src/document.c 2006-10-30 23:00:26 UTC (rev 949)
+++ trunk/src/document.c 2006-11-01 10:58:47 UTC (rev 950)
@@ -1436,7 +1436,7 @@
linebuf = sci_get_line(doc_list[idx].sci, line);
while (isspace(linebuf[i])) i++;
- while (isspace(linebuf[len-1])) len--;
+ while (len > 1 && len > i && isspace(linebuf[len-1])) len--;
g_free(linebuf);
current_mask = sci_get_style_at(doc_list[idx].sci, start);
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