[tracker/dbus-fd-experiment: 3/13] Steroids: Fix crasher when a cell is null



commit 5140ff9d008a012a1eeeafd9a8cfb89d8743b911
Author: Adrien Bustany <abustany gnome org>
Date:   Fri May 21 12:21:56 2010 -0400

    Steroids: Fix crasher when a cell is null

 src/tracker-store/tracker-steroids.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/src/tracker-store/tracker-steroids.c b/src/tracker-store/tracker-steroids.c
index a0d0d79..33f58d1 100644
--- a/src/tracker-store/tracker-steroids.c
+++ b/src/tracker-store/tracker-steroids.c
@@ -207,7 +207,7 @@ query_inthread (TrackerDBCursor *cursor,
 
 			str = tracker_db_cursor_get_string (cursor, i);
 
-			column_sizes[i] = strlen (str);
+			column_sizes[i] = str ? strlen (str) : 0;
 			column_data[i]  = str;
 
 			last_offset += column_sizes[i] + 1;



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