tracker r1569 - in branches/indexer-split: . src/libtracker-common src/trackerd
- From: mr svn gnome org
- To: svn-commits-list gnome org
- Subject: tracker r1569 - in branches/indexer-split: . src/libtracker-common src/trackerd
- Date: Tue, 3 Jun 2008 10:31:13 +0000 (UTC)
Author: mr
Date: Tue Jun 3 10:31:13 2008
New Revision: 1569
URL: http://svn.gnome.org/viewvc/tracker?rev=1569&view=rev
Log:
* src/libtracker-common/tracker-file-utils.h: Fixed includes so we
don't get warnings if glib isn't already included.
* src/trackerd/tracker-db-email.c:
* src/trackerd/tracker-db-sqlite.c:
* src/trackerd/tracker-db.[ch]:
* src/trackerd/tracker-files.c:
* src/trackerd/tracker-main.c:
* src/trackerd/tracker-process-files.c:
* src/trackerd/tracker-watcher-inotify.c: Removed a lot of
tracker_db_() API which is only needed by the indexer.
Modified:
branches/indexer-split/ChangeLog
branches/indexer-split/src/libtracker-common/tracker-file-utils.h
branches/indexer-split/src/trackerd/tracker-db-email.c
branches/indexer-split/src/trackerd/tracker-db-sqlite.c
branches/indexer-split/src/trackerd/tracker-db.c
branches/indexer-split/src/trackerd/tracker-db.h
branches/indexer-split/src/trackerd/tracker-files.c
branches/indexer-split/src/trackerd/tracker-main.c
branches/indexer-split/src/trackerd/tracker-process-files.c
branches/indexer-split/src/trackerd/tracker-watcher-inotify.c
Modified: branches/indexer-split/src/libtracker-common/tracker-file-utils.h
==============================================================================
--- branches/indexer-split/src/libtracker-common/tracker-file-utils.h (original)
+++ branches/indexer-split/src/libtracker-common/tracker-file-utils.h Tue Jun 3 10:31:13 2008
@@ -22,6 +22,8 @@
#ifndef __LIBTRACKER_COMMON_FILE_UTILS_H__
#define __LIBTRACKER_COMMON_FILE_UTILS_H__
+#include <glib.h>
+
gint tracker_file_open (const gchar *uri,
gboolean readahead);
void tracker_file_close (gint fd,
Modified: branches/indexer-split/src/trackerd/tracker-db-email.c
==============================================================================
--- branches/indexer-split/src/trackerd/tracker-db-email.c (original)
+++ branches/indexer-split/src/trackerd/tracker-db-email.c Tue Jun 3 10:31:13 2008
@@ -692,7 +692,7 @@
uri = g_strconcat (mm->uri, "/", ma->attachment_name, NULL);
g_message ("Indexing attachment with uri:'%s' and mime:'%s'",
uri, attachment_info->mime);
- tracker_db_index_file (db_con, attachment_info, uri, attachment_service);
+ /* tracker_db_index_file (db_con, attachment_info, uri, attachment_service); */
g_free (uri);
tracker_db_file_info_unref (attachment_info);
Modified: branches/indexer-split/src/trackerd/tracker-db-sqlite.c
==============================================================================
--- branches/indexer-split/src/trackerd/tracker-db-sqlite.c (original)
+++ branches/indexer-split/src/trackerd/tracker-db-sqlite.c Tue Jun 3 10:31:13 2008
@@ -4172,7 +4172,7 @@
guint32 id = tracker_db_get_file_id (db_con, moved_from_uri);
if (id == 0) {
g_warning ("Original file:'%s' not found in database", moved_from_uri);
- tracker_db_insert_pending_file (db_con, id, moved_to_uri, NULL, "unknown", 0, TRACKER_DB_ACTION_WRITABLE_FILE_CLOSED, FALSE, TRUE, -1);
+ /* tracker_db_insert_pending_file (db_con, id, moved_to_uri, NULL, "unknown", 0, TRACKER_DB_ACTION_WRITABLE_FILE_CLOSED, FALSE, TRUE, -1); */
tracker_db_interface_end_transaction (db_con->db);
return;
}
Modified: branches/indexer-split/src/trackerd/tracker-db.c
==============================================================================
--- branches/indexer-split/src/trackerd/tracker-db.c (original)
+++ branches/indexer-split/src/trackerd/tracker-db.c Tue Jun 3 10:31:13 2008
@@ -20,49 +20,14 @@
* Boston, MA 02110-1301, USA.
*/
-#include <stdlib.h>
-#include <string.h>
-#include <time.h>
+#include "config.h"
-#include <glib/gstdio.h>
-
-#include <libtracker-common/tracker-log.h>
-#include <libtracker-common/tracker-config.h>
#include <libtracker-common/tracker-file-utils.h>
-#include <libtracker-common/tracker-type-utils.h>
-#include <libtracker-common/tracker-ontology.h>
#include <libtracker-common/tracker-os-dependant.h>
#include "tracker-db.h"
-#include "tracker-email.h"
#include "tracker-process-files.h"
-extern Tracker *tracker;
-
-#define XMP_MIME_TYPE "application/rdf+xml"
-#define STACK_SIZE 30
-#define BLACK_LIST_SECONDS 3600
-#define MAX_DURATION 180
-#define MAX_CHANGE_TIMES 3
-
-typedef struct {
- DBConnection *db_con;
- char *file_id;
- char *service;
- GHashTable *table;
-} DatabaseAction;
-
-static GQueue *file_change_queue;
-static gboolean black_list_timer_active;
-
-static void
-free_metadata_list (GSList *list)
-{
- g_slist_foreach (list, (GFunc) g_free, NULL);
- g_slist_free (list);
-
-}
-
gboolean
tracker_db_is_file_up_to_date (DBConnection *db_con, const char *uri, guint32 *id)
{
@@ -107,7 +72,6 @@
return TRUE;
}
-
guint32
tracker_db_get_file_id (DBConnection *db_con, const char *uri)
{
@@ -141,7 +105,6 @@
return id;
}
-
TrackerDBFileInfo *
tracker_db_get_file_info (DBConnection *db_con, TrackerDBFileInfo *info)
{
@@ -158,14 +121,8 @@
name = g_path_get_basename (info->uri);
path = g_path_get_dirname (info->uri);
- //apath = tracker_escape_string (path);
- //aname = tracker_escape_string (name);
-
result_set = tracker_exec_proc (db_con, "GetServiceID", path, name, NULL);
-// g_free (aname);
-// g_free (apath);
-
g_free (name);
g_free (path);
@@ -195,131 +152,6 @@
return info;
}
-
-
-static void
-add_embedded_keywords (DBConnection *db_con, const char *service, const char *file_id, const char *keyword_type, const char *keywords, GHashTable *table)
-{
- char **array;
-
- if (!service) {
- return;
- }
-
- array = g_strsplit_set (keywords, "\t\n\v\f\r !\"#$%&'()*/<=>?[\\]^`{|}~+,.:;@\"[]", -1);
-
- tracker_db_insert_embedded_metadata (db_con, service, file_id, keyword_type, array, -1, table);
-
- g_strfreev (array);
-}
-
-
-
-static void
-save_meta_table_data (gpointer mtype,
- gpointer value,
- gpointer user_data)
-{
- DatabaseAction *db_action;
-
- if (mtype == NULL || value == NULL) {
- return;
- }
-
- db_action = user_data;
-
- /* auto-tag keyword related metadata */
- if (tracker_ontology_field_is_child_of (mtype, "DC:Keywords")) {
-
- GSList *tmp;
- for (tmp = value; tmp; tmp = tmp->next) {
-
- if (tmp->data) {
- add_embedded_keywords (db_action->db_con, db_action->service, db_action->file_id, mtype, tmp->data, db_action->table);
- }
- }
-
- } else {
- gchar **array = tracker_gslist_to_string_list (value);
-
- tracker_db_insert_embedded_metadata (db_action->db_con, db_action->service, db_action->file_id, mtype, array, g_slist_length (value), db_action->table);
-
- g_strfreev (array);
- }
-
-}
-
-
-GHashTable *
-tracker_db_save_metadata (DBConnection *db_con, GHashTable *table, GHashTable *index_table, const char *service, guint32 file_id, gboolean new_file)
-{
- DatabaseAction db_action;
-
- g_return_val_if_fail (db_con, NULL);
- g_return_val_if_fail (table, NULL);
-
- if (file_id == 0) {
- return NULL;
- }
-
- db_action.db_con = db_con;
- db_action.table = index_table;
- db_action.file_id = tracker_uint_to_string (file_id);
- db_action.service = (char *) service;
-
- if (table) {
- g_hash_table_foreach (table, save_meta_table_data, &db_action);
- }
-
- g_free (db_action.file_id);
-
- return db_action.table;
-}
-
-
-void
-tracker_db_save_thumbs (DBConnection *db_con,
- const gchar *small_thumb,
- const gchar *large_thumb,
- guint32 file_id)
-{
-#if 0
- gchar *str_file_id;
-
- str_file_id = tracker_uint_to_string (file_id);
-
- g_return_if_fail (str_file_id);
-
- if (small_thumb) {
- gchar *small_thumb_file;
-
- small_thumb_file = tracker_escape_string (small_thumb);
- tracker_db_set_metadata (db_con,
- "Files", str_file_id,
- "File.SmallThumbnailPath", small_thumb_file,
- TRUE, FALSE, TRUE);
- tracker_exec_proc (db_con, "SetMetadata",
- "Files", str_file_id,
- "File.SmallThumbnailPath", small_thumb_file,
- "1", NULL);
- g_free (small_thumb_file);
- }
-
- if (large_thumb) {
- gchar *large_thumb_file;
-
- large_thumb_file = tracker_escape_string (large_thumb);
- tracker_db_set_metadata (db_con,
- "Files", str_file_id,
- "File.LargeThumbnailPath", large_thumb_file,
- TRUE, FALSE, TRUE);
- g_free (large_thumb_file);
- }
-
- g_free (str_file_id);
-#endif
-}
-
char **
tracker_db_get_files_in_folder (DBConnection *db_con, const char *folder_uri)
{
@@ -358,1065 +190,12 @@
return (gchar **) g_ptr_array_free (array, FALSE);
}
-TrackerDBFileInfo *
-tracker_db_get_pending_file (DBConnection *db_con, const char *uri)
-{
- TrackerDBResultSet *result_set;
- TrackerDBFileInfo *info;
-
- info = NULL;
- result_set = tracker_exec_proc (db_con->cache, "SelectPendingByUri", uri, NULL);
-
- if (result_set) {
- gboolean is_directory, is_new, extract_embedded, extract_contents;
- gint counter, service_type_id;
- gchar *mimetype;
-
- tracker_db_result_set_get (result_set,
- 2, &counter,
- 3, &mimetype,
- 4, &is_directory,
- 5, &is_new,
- 6, &extract_embedded,
- 7, &extract_contents,
- 8, &service_type_id,
- -1);
-
- info = tracker_db_file_info_new (uri, counter, 0, 0);
- info->mime = mimetype;
- info->is_directory = is_directory;
- info->is_new = is_new;
- info->extract_embedded = extract_embedded;
- info->extract_contents = extract_contents;
- info->service_type_id = service_type_id;
-
- g_object_unref (result_set);
- }
-
- return info;
-}
-
-static void
-notify_meta_data_available (void)
-{
- if (!tracker->is_running) {
- return;
- }
-
- /* If metadata thread is asleep then we just need to wake it
- * up!
- */
- if (g_mutex_trylock (tracker->metadata_signal_mutex)) {
- g_cond_signal (tracker->metadata_signal_cond);
- g_mutex_unlock (tracker->metadata_signal_mutex);
- return;
- }
-
- /* If busy - check if async queue has new stuff as we do not
- * need to notify then.
- */
- if (tracker_process_files_metadata_queue_length () > 1) {
- return;
- }
-
- /* If metadata thread not in check phase then we need do
- * nothing
- */
- if (g_mutex_trylock (tracker->metadata_check_mutex)) {
- g_mutex_unlock (tracker->metadata_check_mutex);
- return;
- }
-
- /* We are in check phase - we need to wait until either
- * check_mutex is unlocked or until metadata thread is asleep
- * then we awaken it.
- */
- while (TRUE) {
- if (g_mutex_trylock (tracker->metadata_check_mutex)) {
- g_mutex_unlock (tracker->metadata_check_mutex);
- return;
- }
-
- if (g_mutex_trylock (tracker->metadata_signal_mutex)) {
- g_cond_signal (tracker->metadata_signal_cond);
- g_mutex_unlock (tracker->metadata_signal_mutex);
- return;
- }
-
- g_thread_yield ();
- g_usleep (10);
-
- g_debug ("In check phase");
- }
-}
-
-static void
-make_pending_file (DBConnection *db_con,
- guint32 file_id,
- const char *uri,
- const char *moved_to_uri,
- const char *mime,
- int counter,
- TrackerDBAction action,
- gboolean is_directory,
- gboolean is_new,
- int service_type_id)
-{
- char *str_file_id, *str_action, *str_counter;
-
- g_return_if_fail (tracker_check_uri (uri));
-
- str_file_id = tracker_uint_to_string ( file_id);
- str_action = tracker_int_to_string (action);
- str_counter = tracker_int_to_string (counter);
-
- if (tracker->is_running) {
-
- gboolean move_file = (action == TRACKER_DB_ACTION_FILE_MOVED_FROM || action == TRACKER_DB_ACTION_DIRECTORY_MOVED_FROM);
-
- if (!move_file &&
- ((counter > 0) ||
- (tracker_process_files_process_queue_length () > tracker->max_process_queue_size))) {
-
- /* g_message ("************ counter for pending file %s is %d ***********", uri, counter); */
- if (!mime) {
- tracker_db_insert_pending (db_con, str_file_id, str_action, str_counter, uri, "unknown", is_directory, is_new, service_type_id);
- } else {
- tracker_db_insert_pending (db_con, str_file_id, str_action, str_counter, uri, mime, is_directory, is_new, service_type_id);
- }
-
- } else {
-
- TrackerDBFileInfo *info;
-
- info = tracker_db_file_info_new (uri, action, 0, TRACKER_DB_WATCH_OTHER);
-
- info->is_directory = is_directory;
- info->is_new = is_new;
-
- if (!mime) {
- info->mime = g_strdup ("unknown");
- } else {
- info->mime = g_strdup (mime);
- }
-
- if (action == TRACKER_DB_ACTION_FILE_MOVED_FROM ||
- action == TRACKER_DB_ACTION_DIRECTORY_MOVED_FROM) {
- info->moved_to_uri = g_strdup (moved_to_uri);
- }
-
- if (action != TRACKER_DB_ACTION_EXTRACT_METADATA) {
- tracker_process_files_process_queue_push (info);
- } else {
- tracker_process_files_metadata_queue_push (info);
- }
- }
-
- } else {
- g_free (str_file_id);
- g_free (str_action);
- g_free (str_counter);
- return;
- }
-
- /* g_message ("inserting pending file for %s with action %s", uri, tracker_actions[action]); */
-
- /* signal respective thread that data is available and awake it if its asleep */
- if (action == TRACKER_DB_ACTION_EXTRACT_METADATA) {
- notify_meta_data_available ();
- } else {
- tracker_notify_file_data_available ();
- }
-
- g_free (str_file_id);
- g_free (str_action);
- g_free (str_counter);
-}
-
-
-void
-tracker_db_update_pending_file (DBConnection *db_con, const char *uri, int counter, TrackerDBAction action)
-{
- char *str_counter, *str_action;
-
- g_return_if_fail (tracker_check_uri (uri));
-
- str_counter = tracker_int_to_string (counter);
- str_action = tracker_int_to_string (action);
-
- if (tracker->is_running) {
- tracker_db_update_pending (db_con, str_counter, str_action, uri);
- }
-
- g_free (str_counter);
- g_free (str_action);
-}
-
-static void
-refresh_file_change_queue (gpointer data, gpointer user_data)
-{
- TrackerDBFileChange *change = (TrackerDBFileChange*) data;
- gint *current = (gint *)user_data;
-
- if ((*current - change->first_change_time) > MAX_DURATION) {
- g_queue_remove_all (file_change_queue, data);
- tracker_db_file_change_free (&change);
- }
-}
-
-static gint
-uri_comp (gconstpointer a, gconstpointer b)
-{
- TrackerDBFileChange *change = (TrackerDBFileChange *) a;
- char *valuea = change->uri;
- char *valueb = (char *)b;
-
- return strcmp (valuea, valueb);
-}
-
-static gint
-file_change_sort_comp (gconstpointer a, gconstpointer b, gpointer user_data)
-{
- TrackerDBFileChange *changea, *changeb;
- changea = (TrackerDBFileChange *)a;
- changeb = (TrackerDBFileChange *)b;
-
- if ((changea->num_of_change - changeb->num_of_change) == 0) {
- return changea->first_change_time - changeb->first_change_time;
- } else {
- return changea->num_of_change - changeb->num_of_change;
- }
-}
-
-static void
-print_file_change_queue (void)
-{
- GList *head, *l;
- TrackerDBFileChange *change;
- gint count;
-
- head = g_queue_peek_head_link (file_change_queue);
-
- g_message ("File Change queue is:");
- count = 1;
- for (l = g_list_first (head); l != NULL; l = g_list_next (l)) {
- change = (TrackerDBFileChange*) l->data;
- g_message ("%d\t%s\t%d\t%d",
- count++,
- change->uri,
- (gint) change->first_change_time,
- change->num_of_change);
- }
-
-}
-
-static void
-free_file_change_queue (gpointer data, gpointer user_data)
-{
- TrackerDBFileChange *change = (TrackerDBFileChange *) data;
- tracker_db_file_change_free (&change);
-}
-
-static void
-index_blacklist_file (char *uri)
-{
- TrackerDBFileInfo *info;
-
- info = tracker_db_file_info_new (uri, TRACKER_DB_ACTION_FILE_CHECK, 0, TRACKER_DB_WATCH_OTHER);
-
- info->is_directory = FALSE;
-
- info->is_new = FALSE;
-
- info->mime = g_strdup ("unknown");
-
- tracker_process_files_process_queue_push (info);
-
- tracker_notify_file_data_available ();
-
-}
-
-
-static gboolean
-index_black_list ()
-{
- GSList *black_list;
-
- black_list = tracker_process_files_get_temp_black_list ();
- g_slist_foreach (black_list,
- (GFunc) index_blacklist_file,
- NULL);
- g_slist_free (black_list);
-
- tracker_process_files_set_temp_black_list (NULL);
-
- black_list_timer_active = FALSE;
-
- return FALSE;
-
-}
-
-
-
-static gboolean
-check_uri_changed_frequently (const char *uri)
-{
- GList *find;
- TrackerDBFileChange *change;
- time_t current;
-
- current = time (NULL);
-
- /* remove items which are very old */
- g_queue_foreach (file_change_queue,
- refresh_file_change_queue, ¤t);
-
- find = g_queue_find_custom (file_change_queue, uri, uri_comp);
- if (!find) {
- /* not found, add to in the queue */
-
- change = g_new0 (TrackerDBFileChange, 1);
- change->uri = g_strdup (uri);
- change->first_change_time = current;
- change->num_of_change = 1;
- if (g_queue_get_length (file_change_queue) == STACK_SIZE) {
- TrackerDBFileChange *tmp = g_queue_pop_head (file_change_queue);
- tracker_db_file_change_free (&tmp);
- }
- g_queue_insert_sorted (file_change_queue, change,
- file_change_sort_comp, NULL);
- print_file_change_queue ();
- return FALSE;
- } else {
- change = (TrackerDBFileChange *) find->data;
- (change->num_of_change)++;
- g_queue_sort (file_change_queue,
- file_change_sort_comp, NULL);
- if (change->num_of_change < MAX_CHANGE_TIMES) {
- print_file_change_queue ();
- return FALSE;
- } else {
- print_file_change_queue ();
-
- /* add uri to blacklist */
-
- g_message ("blacklisting %s", change->uri);
-
- tracker_process_files_append_temp_black_list (change->uri);
-
- if (!black_list_timer_active) {
- black_list_timer_active = TRUE;
- g_timeout_add_seconds (BLACK_LIST_SECONDS,
- (GSourceFunc) index_black_list,
- NULL);
- }
-
- g_queue_remove_all (file_change_queue, change);
- tracker_db_file_change_free (&change);
-
- return TRUE;
- }
- }
-
-}
-
-void
-tracker_db_insert_pending_file (DBConnection *db_con, guint32 file_id, const char *uri, const char *moved_to_uri, const char *mime, int counter, TrackerDBAction action, gboolean is_directory, gboolean is_new, int service_type_id)
-{
- TrackerDBFileInfo *info;
-
- g_return_if_fail (tracker_check_uri (uri));
-
- /* check if uri changed too frequently */
- if (((action == TRACKER_DB_ACTION_CHECK) ||
- (action == TRACKER_DB_ACTION_FILE_CHECK) || (action == TRACKER_DB_ACTION_WRITABLE_FILE_CLOSED)) &&
- check_uri_changed_frequently (uri)) {
-
- return;
- }
-
-
- /* check if uri already has a pending action and update accordingly */
- info = tracker_db_get_pending_file (db_con, uri);
-
- if (info) {
- switch (action) {
-
- case TRACKER_DB_ACTION_FILE_CHECK:
-
- /* update counter for any existing event in the file_scheduler */
-
- if ((info->action == TRACKER_DB_ACTION_FILE_CHECK) ||
- (info->action == TRACKER_DB_ACTION_FILE_CREATED) ||
- (info->action == TRACKER_DB_ACTION_FILE_CHANGED)) {
-
- tracker_db_update_pending_file (db_con, uri, counter, action);
- }
-
- break;
-
- case TRACKER_DB_ACTION_FILE_CHANGED:
-
- tracker_db_update_pending_file (db_con, uri, counter, action);
-
- break;
-
- case TRACKER_DB_ACTION_WRITABLE_FILE_CLOSED:
-
- tracker_db_update_pending_file (db_con, uri, 0, action);
-
- break;
-
- case TRACKER_DB_ACTION_FILE_DELETED:
- case TRACKER_DB_ACTION_FILE_CREATED:
- case TRACKER_DB_ACTION_DIRECTORY_DELETED:
- case TRACKER_DB_ACTION_DIRECTORY_CREATED:
-
- /* overwrite any existing event in the file_scheduler */
- tracker_db_update_pending_file (db_con, uri, 0, action);
-
- break;
-
- case TRACKER_DB_ACTION_EXTRACT_METADATA:
-
- /* we only want to continue extracting metadata if file is not being changed/deleted in any way */
- if (info->action == TRACKER_DB_ACTION_FILE_CHECK) {
- tracker_db_update_pending_file (db_con, uri, 0, action);
- }
-
- break;
-
- default:
- break;
- }
-
- tracker_db_file_info_free (info);
-
- } else {
- make_pending_file (db_con, file_id, uri, moved_to_uri, mime, counter, action, is_directory, is_new, service_type_id);
- }
-}
-
-
-static void
-restore_backup_data (gpointer mtype,
- gpointer value,
- gpointer user_data)
-{
- DatabaseAction *db_action;
- gchar **string_list;
-
- if (mtype == NULL || value == NULL) {
- return;
- }
-
- db_action = user_data;
-
- string_list = tracker_gslist_to_string_list (value);
- g_message ("restoring keyword list with %d items", g_slist_length (value));
-
- tracker_db_set_metadata (db_action->db_con, db_action->service, db_action->file_id, mtype, string_list, g_slist_length (value), FALSE);
-
- g_strfreev (string_list);
-}
-
-
-
-void
-tracker_db_index_service (DBConnection *db_con,
- TrackerDBFileInfo *info,
- const gchar *service,
- GHashTable *meta_table,
- const gchar *attachment_uri,
- const gchar *attachment_service,
- gboolean get_embedded,
- gboolean get_full_text,
- gboolean get_thumbs)
-{
- gchar *str_file_id;
- const gchar *uri;
- GHashTable *index_table, *old_table;
-
- if (!service) {
- /* It's an external service - TODO get external service name */
- if (service) {
- g_message ("External service %s not supported yet", service);
- } else {
- g_message ("External service not supported yet");
- }
- return;
- }
-
- if (!attachment_uri) {
- uri = info->uri;
- } else {
- uri = attachment_uri;
- }
-
- info->service_type_id = tracker_ontology_get_id_for_service_type (service);
-
- if (info->service_type_id == -1) {
- g_message ("Service %s not supported yet", service);
- return;
- }
-
- if (info->mime == NULL) {
- info->mime = g_strdup("unknown");
- }
-
- if (info->is_new) {
- if (info->mime)
- g_message ("Indexing:'%s' with service:'%s' and mime:'%s' (new)",
- uri, service, info->mime);
- else
- g_message ("Indexing:'%s' with service:'%s' (new)",
- uri, service);
- } else {
- if (info->mime)
- g_message ("Indexing:'%s' with service:'%s' and mime:'%s' (existing)",
- uri, service, info->mime);
- else
- g_message ("Indexing:'%s' with service:'%s' (existing)",
- uri, service);
- }
-
- if (!info->is_new) {
- old_table = g_hash_table_new (g_str_hash, g_str_equal);
- } else {
- old_table = NULL;
- }
-
- index_table = g_hash_table_new (g_str_hash, g_str_equal);
-
-#if 0
- /* FIXME-indexer-split: This has been commented out as a
- * result of moving tracker-metadata.[ch] to the indexer
- * directory. This code will be removed when this function is
- * updated to work correctly in the indexer application.
- *
- * -Martyn
- */
-
- /* get embedded metadata filter */
- if (get_embedded && meta_table) {
- tracker_metadata_get_embedded (info->uri, info->mime, meta_table);
- }
-#endif
-
- if (info->is_new) {
- gchar *old_uri;
-
- old_uri = info->uri;
- info->uri = (gchar *) uri;
-
- if (attachment_service) {
- info->file_id = tracker_db_create_service (db_con, attachment_service, info);
- } else {
- info->file_id = tracker_db_create_service (db_con, service, info);
- }
-
- info->uri = old_uri;
-
- if (info->file_id == 0) {
- g_critical ("Could not get file id for:'%s', unable to continue indexing this file", uri);
- return;
- }
-
- if (info->service_type_id == -1) {
- g_critical ("Unknown service type for:'%s' with service:'%s' and mime %s", uri, service, info->mime);
- }
- }
-
- str_file_id = tracker_uint_to_string (info->file_id);
-
- if (get_thumbs && tracker_config_get_enable_thumbnails (tracker->config)) {
-#if 0
- gchar *small_thumb_file = NULL;
-
- /* FIXME-indexer-split: This has been commented out as a
- * result of moving tracker-metadata.[ch] to the indexer
- * directory. This code will be removed when this function is
- * updated to work correctly in the indexer application.
- *
- * -Martyn
- */
- small_thumb_file = tracker_metadata_get_thumbnail (info->uri, info->mime, "normal");
- g_free (small_thumb_file);
-#endif
- }
-
-
- if (!info->is_new) {
- /* get original text for the differential indexer */
- old_table = tracker_db_get_file_contents_words (db_con->blob, info->file_id, old_table);
- }
-
-
- if (get_full_text && tracker_config_get_enable_content_indexing (tracker->config)) {
- gchar *file_as_text = NULL;
-#if 0
-
- /* FIXME-indexer-split: This has been commented out as a
- * result of moving tracker-metadata.[ch] to the indexer
- * directory. This code will be removed when this function is
- * updated to work correctly in the indexer application.
- *
- * -Martyn
- */
- file_as_text = tracker_metadata_get_text_file (info->uri, info->mime);
-#endif
-
- if (file_as_text) {
- tracker_db_save_file_contents (db_con,
- index_table,
- old_table,
- file_as_text,
- info);
-
- /* clear up if text contents are in a temp file */
- if (g_str_has_prefix (file_as_text, tracker_get_sys_tmp_dir ())) {
- g_unlink (file_as_text);
- }
-
- g_free (file_as_text);
- } else {
- get_full_text = FALSE;
- }
- }
-
- if (attachment_service) {
- info->service_type_id = tracker_ontology_get_id_for_service_type (attachment_service);
- }
-
- /* Save stuff to Db */
- if (!info->is_new) {
- /* Update existing file entry */
- tracker_db_update_file (db_con, info);
-
- /* Get original embedded metadata for the differential indexer */
- old_table = tracker_db_get_indexable_content_words (db_con, info->file_id, old_table, TRUE);
-
- /* Delete any exisitng embedded metadata */
- tracker_exec_proc (db_con, "DeleteEmbeddedServiceMetadata1", str_file_id, NULL);
- tracker_exec_proc (db_con, "DeleteEmbeddedServiceMetadata2", str_file_id, NULL);
- tracker_exec_proc (db_con, "DeleteEmbeddedServiceMetadata3", str_file_id, NULL);
- }
-
- if (meta_table && (g_hash_table_size (meta_table) > 0)) {
- tracker_db_save_metadata (db_con, meta_table, index_table, service, info->file_id, info->is_new);
- }
-
-#if 0
- /* Update full text indexes */
- if (info->is_new) {
- tracker_db_update_indexes_for_new_service (info->file_id, info->service_type_id, index_table);
- } else {
- tracker_db_update_differential_index (old_table, index_table, str_file_id, info->service_type_id);
- }
-#endif
-
- tracker_parser_text_free (index_table);
- tracker_parser_text_free (old_table);
-
- /* Check for backup user defined metadata */
- if (info->is_new) {
- TrackerDBResultSet *result_set;
- gchar *name = tracker_file_get_vfs_name (info->uri);
- gchar *path = tracker_file_get_vfs_path (info->uri);
-
- result_set = tracker_exec_proc (db_con->common, "GetBackupMetadata", path, name, NULL);
-
- if (result_set) {
- gboolean valid = TRUE;
- GHashTable *meta_table;
- DatabaseAction db_action;
- gchar *key, *value;
-
- meta_table = g_hash_table_new_full (g_str_hash, g_str_equal,
- (GDestroyNotify) g_free,
- (GDestroyNotify) free_metadata_list);
-
- while (valid) {
- tracker_db_result_set_get (result_set,
- 0, &key,
- 1, &value,
- -1);
-
- g_message ("found backup metadata for %s\%s with key %s and value %s", path, name, key, value);
- tracker_add_metadata_to_table (meta_table, key, value);
-
- valid = tracker_db_result_set_iter_next (result_set);
- }
-
- g_object_unref (result_set);
-
- db_action.db_con = db_con;
- db_action.file_id = str_file_id;
-
- if (attachment_service) {
- db_action.service = (char *) attachment_service;
- } else {
- db_action.service = (char *) service;
- }
-
- g_hash_table_foreach (meta_table, restore_backup_data, &db_action);
-
- g_hash_table_destroy (meta_table);
- }
-
- g_free (name);
- g_free (path);
- }
-
- g_free (str_file_id);
-}
-
-
-
-
-void
-tracker_db_index_master_files (DBConnection *db_con, const gchar *dirname, const gchar *basename, const gchar *filename)
-{
- GDir* dir = g_dir_open (dirname, 0, NULL);
-
- if (dir) {
-
- const gchar *curr_ext;
- const gchar *curr_filename;
-
- TrackerDBFileInfo *master_info;
- gchar *master_uri;
-
- while ((curr_filename = g_dir_read_name (dir)) != NULL) {
- curr_ext = strrchr (curr_filename, '.');
- if (!curr_ext) {
- curr_ext = &curr_filename[strlen (curr_filename)];
- }
-
- if (curr_ext+1 && strncmp (basename, curr_filename, curr_ext-curr_filename) == 0 &&
- strcmp (curr_ext+1, "xmp") != 0 &&
- !g_str_has_suffix (curr_ext+1, "~")) {
-
- g_debug ("master file, %s, about to be updated", curr_filename);
-
- master_uri = g_build_filename (dirname, curr_filename, NULL);
- master_info = tracker_db_file_info_new (master_uri, TRACKER_DB_ACTION_FILE_CHANGED, 0, 0);
- master_info = tracker_db_get_file_info (db_con, master_info);
- g_free (master_uri);
-
- tracker_db_index_file (db_con, master_info, NULL, NULL);
- }
- }
-
- g_dir_close (dir);
- }
-}
-
-
-void
-tracker_db_index_file (DBConnection *db_con,
- TrackerDBFileInfo *info,
- const gchar *attachment_uri,
- const gchar *attachment_service)
-{
-
- GHashTable *meta_table;
- const gchar *ext;
- const gchar *uri;
- gchar *filename, *dirname;
- gchar *str_link_uri, *service_name;
- gboolean is_file_indexable;
- gboolean is_external_service;
- gboolean is_sidecar;
- gboolean service_has_metadata;
- gboolean service_has_fulltext;
- gboolean service_has_thumbs;
-
- if (!attachment_uri) {
- uri = info->uri;
- } else {
- uri = attachment_uri;
- }
-
- if (info->mime) {
- g_free (info->mime);
- }
-
- if (info->is_directory) {
- service_name = g_strdup ("Folders");
- info->mime = g_strdup ("Folder");
- info->file_size = 0;
- } else {
- info->mime = tracker_file_get_mime_type (info->uri);
-
- if (!info->mime) {
- info->mime = g_strdup ("unknown");
- }
-
- g_message ("Mime is:'%s' for:'%s'",
- info->mime, info->uri);
-
- service_name = tracker_ontology_get_service_type_for_mime (info->mime);
- }
-
- if (info->is_link) {
- str_link_uri = g_build_filename (info->link_path,
- info->link_name,
- NULL);
- } else {
- str_link_uri = NULL;
- }
-
- if (!info->is_hidden) {
- meta_table = g_hash_table_new_full (g_str_hash,
- g_str_equal,
- g_free,
- (GDestroyNotify) free_metadata_list);
-
- tracker_add_metadata_to_table (meta_table,
- g_strdup ("File:NameDelimited"),
- g_strdup (uri));
-
- dirname = g_path_get_dirname (uri);
- filename = g_path_get_basename (uri);
- ext = strrchr (filename, '.');
-
- if (ext) {
- ext++;
- g_debug ("file extension is %s", ext);
- tracker_add_metadata_to_table (meta_table,
- g_strdup ("File:Ext"),
- g_strdup (ext));
- is_sidecar = strcmp("xmp",ext) == 0;
- } else {
- is_sidecar = FALSE;
- }
-
- tracker_add_metadata_to_table (meta_table,
- g_strdup ("File:Path"),
- g_strdup (dirname));
- tracker_add_metadata_to_table (meta_table,
- g_strdup ("File:Name"),
- g_strdup (filename));
-
- if (str_link_uri) {
- tracker_add_metadata_to_table (meta_table, g_strdup ("File:Link"), str_link_uri);
- }
-
- tracker_add_metadata_to_table (meta_table,
- g_strdup ("File:Mime"),
- g_strdup (info->mime));
- tracker_add_metadata_to_table (meta_table,
- g_strdup ("File:Size"),
- tracker_uint_to_string (info->file_size));
- tracker_add_metadata_to_table (meta_table,
- g_strdup ("File:Modified"),
- tracker_date_to_string (info->mtime));
- tracker_add_metadata_to_table (meta_table,
- g_strdup ("File:Accessed"),
- tracker_date_to_string (info->atime));
-
- /* need to add special data for web history */
- if (attachment_service != NULL &&
- strcmp(attachment_service,"WebHistory") == 0) {
- gchar *meta_file;
- FILE *fp;
-
- meta_file = g_strconcat(dirname,"/.",filename,NULL);
- fp = g_fopen(meta_file, "r");
-
- if (fp != NULL) {
- gchar buf[512];
-
- fgets (buf,512,fp); /* Get the first
- * line, it is
- * URL for this
- * web history
- * object
- */
-
- g_debug("URL for this WebHistory is %s\n",buf);
- tracker_add_metadata_to_table (meta_table, g_strdup ("Doc:URL"), g_strdup(buf));
-
- fgets (buf,512,fp);
- fgets (buf,512,fp);
- fgets (buf,512,fp);
- fgets (buf,512,fp); /* Get the
- * keywords for
- * this file
- */
-
- if (buf != NULL) {
- gchar **keys;
-
- /* Format like t:dc:keyword=xxx */
- keys = g_strsplit (buf, "=", 0);
-
- if (keys != NULL &&
- strcmp (keys[0], "t:dc:keyword") == 0 &&
- keys[1]) {
- gchar *doc_keyword;
-
- doc_keyword = g_strdup (keys[1]);
- g_debug("found keywords : %s\n",doc_keyword);
- tracker_add_metadata_to_table (meta_table,
- g_strdup ("Doc:Keywords"),
- doc_keyword);
- }
-
- if (keys) {
- g_strfreev(keys);
- }
- }
-
- fclose (fp);
- }
-
- g_free (meta_file);
- }
-
- is_external_service = g_str_has_prefix (info->mime, "service/");
- is_file_indexable = (!info->is_directory &&
- (strcmp (info->mime, "unknown") != 0) &&
- (strcmp (info->mime, "symlink") != 0) &&
- tracker_file_is_indexable (info->uri));
-
- service_has_metadata =
- (is_external_service ||
- (is_file_indexable &&
- tracker_ontology_service_type_has_metadata (service_name))) &&
- !is_sidecar;
- service_has_fulltext =
- (is_external_service ||
- (is_file_indexable &&
- tracker_ontology_service_type_has_text (service_name))) &&
- !is_sidecar;
- service_has_thumbs =
- (is_external_service ||
- (is_file_indexable &&
- tracker_ontology_service_type_has_thumbnails (service_name)));
-
-#ifdef HAVE_EXEMPI
- if (!info->is_directory) {
- gchar *basename;
-
- if (ext) {
- basename = g_strndup (filename, (ext - filename - 1));
- } else {
- basename = g_strdup (filename);
- }
-
- if (is_sidecar) {
- tracker_db_index_master_files (db_con, dirname, basename, filename);
- } else {
- gchar *sidecar_filename;
- gchar *sidecar_uri;
-
- sidecar_filename = g_strconcat (basename, ".xmp", NULL);
- sidecar_uri = g_build_filename (dirname, sidecar_filename, NULL);
-
-#if 0
- if (g_file_test (sidecar_uri, G_FILE_TEST_EXISTS)) {
- g_debug ("xmp sidecar found for %s", uri);
-
- /* FIXME-indexer-split: This has been commented out as a
- * result of moving tracker-metadata.[ch] to the indexer
- * directory. This code will be removed when this function is
- * updated to work correctly in the indexer application.
- *
- * -Martyn
- */
- tracker_metadata_get_embedded (sidecar_uri, XMP_MIME_TYPE, meta_table);
- }
-#endif
-
- g_free (sidecar_filename);
- g_free (sidecar_uri);
- }
- g_free (basename);
- }
-#endif /* HAVE_EXEMPI */
-
- g_debug ("file %s has fulltext %d with service %s",
- info->uri, service_has_fulltext, service_name);
- tracker_db_index_service (db_con,
- info,
- service_name,
- meta_table,
- uri,
- attachment_service,
- service_has_metadata,
- service_has_fulltext,
- service_has_thumbs);
-
- g_hash_table_destroy (meta_table);
-
- g_free (filename);
- g_free (dirname);
- } else {
- tracker_db_index_service (db_con,
- info,
- service_name,
- NULL,
- uri,
- NULL,
- FALSE,
- FALSE,
- FALSE);
- }
-
- g_free (service_name);
-
- if (attachment_uri) {
- tracker_file_unlink (info->uri);
- }
-
- tracker_db_file_info_unref (info);
-}
-
-void
-tracker_db_index_conversation (DBConnection *db_con, TrackerDBFileInfo *info)
-{
- /* to do use offsets */
-
- tracker_db_index_file (db_con, info, NULL, "GaimConversations");
-}
-
-void
-tracker_db_index_webhistory(DBConnection *db_con, TrackerDBFileInfo *info)
-{
- tracker_db_index_file (db_con, info, NULL, "WebHistory");
-}
-
-void
-tracker_db_file_change_free (TrackerDBFileChange **change)
-{
- g_return_if_fail (change != NULL);
-
- g_free ((*change)->uri);
- (*change)->uri = NULL;
- *change = NULL;
-}
-
void
tracker_db_init (void)
{
- if (file_change_queue) {
- return;
- }
-
- file_change_queue = g_queue_new ();
}
void
tracker_db_shutdown (void)
{
- if (!file_change_queue) {
- return;
- }
-
- g_queue_foreach (file_change_queue,
- free_file_change_queue, NULL);
- g_queue_free (file_change_queue);
- file_change_queue = NULL;
}
Modified: branches/indexer-split/src/trackerd/tracker-db.h
==============================================================================
--- branches/indexer-split/src/trackerd/tracker-db.h (original)
+++ branches/indexer-split/src/trackerd/tracker-db.h Tue Jun 3 10:31:13 2008
@@ -21,23 +21,14 @@
#ifndef __TRACKERD_DB_H__
#define __TRACKERD_DB_H__
-#include "config.h"
-
#include <glib.h>
#include <libtracker-db/tracker-db-file-info.h>
-#include "tracker-utils.h"
#include "tracker-db-sqlite.h"
G_BEGIN_DECLS
-typedef struct {
- gchar *uri;
- time_t first_change_time;
- gint num_of_change;
-} TrackerDBFileChange;
-
void tracker_db_init (void);
void tracker_db_shutdown (void);
gboolean tracker_db_is_file_up_to_date (DBConnection *db_con,
@@ -45,49 +36,11 @@
guint32 *id);
TrackerDBFileInfo *tracker_db_get_file_info (DBConnection *db_con,
TrackerDBFileInfo *info);
-gboolean tracker_is_valid_service (DBConnection *db_con,
- const gchar *service);
gchar * tracker_db_get_id (DBConnection *db_con,
const gchar *service,
const gchar *uri);
-GHashTable * tracker_db_save_metadata (DBConnection *db_con,
- GHashTable *table,
- GHashTable *index_table,
- const gchar *service,
- guint32 file_id,
- gboolean new_file);
-void tracker_db_save_thumbs (DBConnection *db_con,
- const gchar *small_thumb,
- const gchar *large_thumb,
- guint32 file_id);
gchar ** tracker_db_get_files_in_folder (DBConnection *db_con,
const gchar *folder_uri);
-TrackerDBFileInfo *tracker_db_get_pending_file (DBConnection *db_con,
- const gchar *uri);
-void tracker_db_update_pending_file (DBConnection *db_con,
- const gchar *uri,
- gint counter,
- TrackerDBAction action);
-gboolean tracker_db_has_pending_files (DBConnection *db_con);
-gboolean tracker_db_has_pending_metadata (DBConnection *db_con);
-void tracker_db_index_service (DBConnection *db_con,
- TrackerDBFileInfo *info,
- const gchar *service,
- GHashTable *meta_table,
- const gchar *attachment_uri,
- const gchar *attachment_service,
- gboolean get_embedded,
- gboolean get_full_text,
- gboolean get_thumbs);
-void tracker_db_index_file (DBConnection *db_con,
- TrackerDBFileInfo *info,
- const gchar *attachment_uri,
- const gchar *attachment_service);
-void tracker_db_index_conversation (DBConnection *db_con,
- TrackerDBFileInfo *info);
-void tracker_db_index_webhistory (DBConnection *db_con,
- TrackerDBFileInfo *info);
-void tracker_db_file_change_free (TrackerDBFileChange **change);
G_END_DECLS
Modified: branches/indexer-split/src/trackerd/tracker-files.c
==============================================================================
--- branches/indexer-split/src/trackerd/tracker-files.c (original)
+++ branches/indexer-split/src/trackerd/tracker-files.c Tue Jun 3 10:31:13 2008
@@ -385,16 +385,16 @@
action = TRACKER_DB_ACTION_FILE_DELETED;
}
- tracker_db_insert_pending_file (db_con,
- file_id,
- uri,
- NULL,
- g_strdup ("unknown"),
- 0,
- action,
- is_directory,
- FALSE,
- -1);
+ /* tracker_db_insert_pending_file (db_con, */
+ /* file_id, */
+ /* uri, */
+ /* NULL, */
+ /* g_strdup ("unknown"), */
+ /* 0, */
+ /* action, */
+ /* is_directory, */
+ /* FALSE, */
+ /* -1); */
g_free (path);
g_free (name);
Modified: branches/indexer-split/src/trackerd/tracker-main.c
==============================================================================
--- branches/indexer-split/src/trackerd/tracker-main.c (original)
+++ branches/indexer-split/src/trackerd/tracker-main.c Tue Jun 3 10:31:13 2008
@@ -106,21 +106,20 @@
* threads are waiting to process them.
*/
-#define ABOUT \
- "Tracker " VERSION "\n" \
+#define ABOUT \
+ "Tracker " VERSION "\n" \
"Copyright (c) 2005-2008 Jamie McCracken (jamiemcc gnome org)\n"
-#define LICENSE \
+#define LICENSE \
"This program is free software and comes without any warranty.\n" \
- "It is licensed under version 2 or later of the General Public " \
- "License which can be viewed at:\n" \
- "\n" \
+ "It is licensed under version 2 or later of the General Public " \
+ "License which can be viewed at:\n" \
+ "\n" \
" http://www.gnu.org/licenses/gpl.txt\n"
/* Public */
Tracker *tracker;
DBConnection *main_thread_db_con;
-DBConnection *main_thread_cache_con;
/* Private */
static GMainLoop *main_loop;
Modified: branches/indexer-split/src/trackerd/tracker-process-files.c
==============================================================================
--- branches/indexer-split/src/trackerd/tracker-process-files.c (original)
+++ branches/indexer-split/src/trackerd/tracker-process-files.c Tue Jun 3 10:31:13 2008
@@ -272,9 +272,9 @@
process_schedule_directory_check_foreach (const gchar *uri,
DBConnection *db_con)
{
- tracker_db_insert_pending_file (db_con, 0, uri, NULL, "unknown", 0,
- TRACKER_DB_ACTION_DIRECTORY_REFRESH,
- TRUE, FALSE, -1);
+ /* tracker_db_insert_pending_file (db_con, 0, uri, NULL, "unknown", 0, */
+ /* TRACKER_DB_ACTION_DIRECTORY_REFRESH, */
+ /* TRUE, FALSE, -1); */
}
static void
@@ -288,8 +288,8 @@
process_my_yield ();
if (!tracker_file_is_directory (uri)) {
- tracker_db_insert_pending_file (db_con, 0, uri, NULL, "unknown", 0,
- TRACKER_DB_ACTION_CHECK, 0, FALSE, -1);
+ /* tracker_db_insert_pending_file (db_con, 0, uri, NULL, "unknown", 0, */
+ /* TRACKER_DB_ACTION_CHECK, 0, FALSE, -1); */
} else {
process_schedule_directory_check_foreach (uri, db_con);
}
Modified: branches/indexer-split/src/trackerd/tracker-watcher-inotify.c
==============================================================================
--- branches/indexer-split/src/trackerd/tracker-watcher-inotify.c (original)
+++ branches/indexer-split/src/trackerd/tracker-watcher-inotify.c Tue Jun 3 10:31:13 2008
@@ -174,16 +174,16 @@
case TRACKER_DB_ACTION_DIRECTORY_CREATED:
info->action = TRACKER_DB_ACTION_DIRECTORY_CREATED;
info->is_directory = TRUE;
- tracker_db_insert_pending_file (main_thread_db_con,
- info->file_id,
- info->uri,
- NULL,
- info->mime,
- 0,
- info->action,
- info->is_directory,
- TRUE,
- -1);
+ /* tracker_db_insert_pending_file (main_thread_db_con, */
+ /* info->file_id, */
+ /* info->uri, */
+ /* NULL, */
+ /* info->mime, */
+ /* 0, */
+ /* info->action, */
+ /* info->is_directory, */
+ /* TRUE, */
+ /* -1); */
tracker_db_file_info_free (info);
break;
case TRACKER_DB_ACTION_FILE_CREATED:
@@ -235,16 +235,16 @@
action = TRACKER_DB_ACTION_DIRECTORY_MOVED_FROM;
}
- tracker_db_insert_pending_file (main_thread_db_con,
- moved_from_info->file_id,
- moved_from_info->uri,
- moved_to_info->uri,
- moved_from_info->mime,
- 0,
- action,
- is_dir,
- TRUE,
- -1);
+ /* tracker_db_insert_pending_file (main_thread_db_con, */
+ /* moved_from_info->file_id, */
+ /* moved_from_info->uri, */
+ /* moved_to_info->uri, */
+ /* moved_from_info->mime, */
+ /* 0, */
+ /* action, */
+ /* is_dir, */
+ /* TRUE, */
+ /* -1); */
move_list = g_slist_remove (move_list, l->data);
item_removed = TRUE;
@@ -268,15 +268,15 @@
info->action = TRACKER_DB_ACTION_WRITABLE_FILE_CLOSED;
}
- tracker_db_insert_pending_file (main_thread_db_con,
- info->file_id, info->uri,
- NULL,
- info->mime,
- 10,
- info->action,
- info->is_directory,
- TRUE,
- -1);
+ /* tracker_db_insert_pending_file (main_thread_db_con, */
+ /* info->file_id, info->uri, */
+ /* NULL, */
+ /* info->mime, */
+ /* 10, */
+ /* info->action, */
+ /* info->is_directory, */
+ /* TRUE, */
+ /* -1); */
tracker_db_file_info_free (info);
break;
}
@@ -284,16 +284,16 @@
case TRACKER_DB_ACTION_WRITABLE_FILE_CLOSED:
g_message ("File:'%s' has finished changing", info->uri);
- tracker_db_insert_pending_file (main_thread_db_con,
- info->file_id,
- info->uri,
- NULL,
- info->mime,
- 0,
- info->action,
- info->is_directory,
- TRUE,
- -1);
+ /* tracker_db_insert_pending_file (main_thread_db_con, */
+ /* info->file_id, */
+ /* info->uri, */
+ /* NULL, */
+ /* info->mime, */
+ /* 0, */
+ /* info->action, */
+ /* info->is_directory, */
+ /* TRUE, */
+ /* -1); */
tracker_db_file_info_free (info);
break;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]