tracker r2129 - in branches/indexer-split: . src/tracker-indexer
- From: carlosg svn gnome org
- To: svn-commits-list gnome org
- Subject: tracker r2129 - in branches/indexer-split: . src/tracker-indexer
- Date: Thu, 21 Aug 2008 10:11:14 +0000 (UTC)
Author: carlosg
Date: Thu Aug 21 10:11:14 2008
New Revision: 2129
URL: http://svn.gnome.org/viewvc/tracker?rev=2129&view=rev
Log:
2008-08-21 Carlos Garnacho <carlos imendio com>
* src/tracker-indexer/tracker-indexer.c (create_update_item)
(should_index_file) (tracker_indexer_file_move): Check return value of
tracker_indexer_module_file_get_service_type(), since it could return
NULL for files the module doesn't handle.
Modified:
branches/indexer-split/ChangeLog
branches/indexer-split/src/tracker-indexer/tracker-indexer.c
Modified: branches/indexer-split/src/tracker-indexer/tracker-indexer.c
==============================================================================
--- branches/indexer-split/src/tracker-indexer/tracker-indexer.c (original)
+++ branches/indexer-split/src/tracker-indexer/tracker-indexer.c Thu Aug 21 10:11:14 2008
@@ -1102,6 +1102,11 @@
guint32 id;
service_type = tracker_indexer_module_file_get_service_type (info->module, info->file);
+
+ if (!service_type) {
+ return;
+ }
+
service_def = tracker_ontology_get_service_type_by_name (service_type);
g_free (service_type);
@@ -1542,6 +1547,11 @@
time_t mtime;
service_type = tracker_indexer_module_file_get_service_type (info->module, info->file);
+
+ if (!service_type) {
+ return FALSE;
+ }
+
service = tracker_ontology_get_service_type_by_name (service_type);
g_free (service_type);
@@ -2042,10 +2052,13 @@
info = path_info_new (module, module_name, to);
service_type = tracker_indexer_module_file_get_service_type (module, info->file);
- service = tracker_ontology_get_service_type_by_name (service_type);
- g_free (service_type);
- tracker_db_move_service (service, from, to);
+ if (service_type) {
+ service = tracker_ontology_get_service_type_by_name (service_type);
+ g_free (service_type);
+
+ tracker_db_move_service (service, from, to);
+ }
dbus_g_method_return (context);
tracker_dbus_request_success (request_id);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]