Revision: 6011 http://geany.svn.sourceforge.net/geany/?rev=6011&view=rev Author: ntrel Date: 2011-10-06 12:02:38 +0000 (Thu, 06 Oct 2011) Log Message: ----------- Initialize invalid matches for safety.
Modified Paths: -------------- trunk/tagmanager/lregex.c
Modified: trunk/tagmanager/lregex.c =================================================================== --- trunk/tagmanager/lregex.c 2011-10-06 00:46:09 UTC (rev 6010) +++ trunk/tagmanager/lregex.c 2011-10-06 12:02:38 UTC (rev 6011) @@ -470,9 +470,10 @@ int i; for (i = 0 ; i < BACK_REFERENCE_COUNT ; ++i) { - int so, eo; - if (!g_match_info_fetch_pos(minfo, i, &so, &eo)) - break; + int so = -1, eo = -1; + /* with GRegex we could get the real match count, but that might + * cause incompatibilities with CTags */ + g_match_info_fetch_pos(minfo, i, &so, &eo); matches [i].start = so; matches [i].length = eo - so; /* a valid match may have both offsets == -1,
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.