[tracker/tracker-0.10-nb276745: 8/8] tracker-extract, tiff: Ignore images in certain directories



commit f1d7d9ac815c6fe9371f423f12cc705494ea25b6
Author: Philip Van Hoof <philip codeminded be>
Date:   Tue Oct 18 12:22:52 2011 +0200

    tracker-extract, tiff: Ignore images in certain directories

 src/tracker-extract/tracker-extract-tiff.c |    7 +++++++
 1 files changed, 7 insertions(+), 0 deletions(-)
---
diff --git a/src/tracker-extract/tracker-extract-tiff.c b/src/tracker-extract/tracker-extract-tiff.c
index d177c3c..834048e 100644
--- a/src/tracker-extract/tracker-extract-tiff.c
+++ b/src/tracker-extract/tracker-extract-tiff.c
@@ -37,6 +37,8 @@
 #include <libtracker-common/tracker-common.h>
 #include <libtracker-extract/tracker-extract.h>
 
+#include "tracker-main.h"
+
 #define CM_TO_INCH          0.393700787
 
 typedef enum {
@@ -294,6 +296,11 @@ extract_tiff (const gchar          *uri,
 
 	filename = g_filename_from_uri (uri, NULL, NULL);
 
+	if (tracker_main_is_file_ignored_in_image_directories (filename)) {
+		g_free (filename);
+		return;
+	}
+
 	fd = g_open (filename, O_RDONLY | O_NOATIME, 0);
 	if (fd == -1 && errno == EPERM) {
 		fd = g_open (filename, O_RDONLY, 0);



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