Re: [Tracker] [PATCH 1/1] tracker-parser: skip empty strings in parser_next



Le lundi 23 novembre 2009 Ã 14:10 +0100, Philip Van Hoof a Ãcrit :
Pushed to master,

Thanks!

Just to say that this fixes crashes that were supposed to be related
with Unac  :-)

Really great!


Laurent.


On Mon, 2009-11-23 at 13:41 +0100, Juan A. Suarez Romero wrote:
This fixes a crash in tracker-store.
---
 src/libtracker-fts/tracker-parser.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/src/libtracker-fts/tracker-parser.c b/src/libtracker-fts/tracker-parser.c
index de059fa..c1161d1 100644
--- a/src/libtracker-fts/tracker-parser.c
+++ b/src/libtracker-fts/tracker-parser.c
@@ -299,7 +299,7 @@ parser_next (TrackerParser *parser,
    start = NULL;
    end = NULL;
 
-   for (p = parser->cursor; *p; p = g_utf8_next_char (p)) {
+   for (p = parser->cursor; *p && *p != '\0'; p = g_utf8_next_char (p)) {
            TrackerParserWordType type;
            gunichar              c;
 


Attachment: signature.asc
Description: Ceci est une partie de message =?ISO-8859-1?Q?num=E9riquement?= =?ISO-8859-1?Q?_sign=E9e?=



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]