[tracker/duplicates: 3/4] go more paranoic
- From: Aleksander Morgado <aleksm src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [tracker/duplicates: 3/4] go more paranoic
- Date: Fri, 23 Jul 2010 08:12:02 +0000 (UTC)
commit 5acebfdb763bacb27b9b10f9077bd94fd6399b31
Author: Aleksander Morgado <aleksander lanedo com>
Date: Thu Jul 22 18:08:29 2010 +0200
go more paranoic
src/libtracker-miner/tracker-miner-fs.c | 25 ++++++++++++++++++++-----
1 files changed, 20 insertions(+), 5 deletions(-)
---
diff --git a/src/libtracker-miner/tracker-miner-fs.c b/src/libtracker-miner/tracker-miner-fs.c
index 4260ca4..a5b38e3 100644
--- a/src/libtracker-miner/tracker-miner-fs.c
+++ b/src/libtracker-miner/tracker-miner-fs.c
@@ -34,9 +34,9 @@
/* If defined will print the tree from GNode while running */
#undef ENABLE_TREE_DEBUGGING
/* If defined will print contents of populated IRI cache while running */
-#undef PRINT_IRI_CACHE_CONTENTS
+#define PRINT_IRI_CACHE_CONTENTS 1
/* If defined will print contents of populated mtime cache while running */
-#undef PRINT_MTIME_CACHE_CONTENTS
+#define PRINT_MTIME_CACHE_CONTENTS 1
/* If defined, will dump paranoic debug logs */
#define PARANOIC_DEBUG_LOGS 1
@@ -608,6 +608,16 @@ process_data_new (GFile *file,
data->builder = g_object_ref (builder);
}
+#ifdef PARANOIC_DEBUG
+ {
+ gchar *uri = g_file_get_uri (file);
+
+ paranoic_debug ("Created data to process %p, for URI '%s' with urn '%s'",
+ data, uri, urn ? urn : "unknown");
+ g_free (uri);
+ }
+#endif /* PARANOIC_DEBUG */
+
return data;
}
@@ -647,8 +657,13 @@ process_data_find (TrackerMinerFS *fs,
* pointer equality here, rather than doing path comparisons
*/
if(data->file == file) {
- paranoic_debug ("Found data to process '%p', looking for file '%p'",
- data, file);
+#ifdef PARANOIC_DEBUG
+ gchar *uri = g_file_get_uri (file);
+
+ paranoic_debug ("Found data to process '%p', looking for file '%p' (%s)",
+ data, file, uri);
+ g_free (uri);
+#endif /* PARANOIC_DEBUG */
return data;
}
} else {
@@ -664,7 +679,7 @@ process_data_find (TrackerMinerFS *fs,
paranoic_debug ("Found data to process '%p', looking for file '%s'",
data, uri);
g_free (uri);
-#endif
+#endif /* PARANOIC_DEBUG */
return data;
}
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]