[Xfce4-commits] <tumbler:jannis/specialized> Fix a bunch of compiler warnings.

Jannis Pohlmann noreply at xfce.org
Tue Oct 27 18:48:07 CET 2009


Updating branch refs/heads/jannis/specialized
         to 4b130f4bae4dfcd96fb1fcd98ab5b9863b077df3 (commit)
       from 7fab6a44ab5fecb2a388c3eac8780364736fc60a (commit)

commit 4b130f4bae4dfcd96fb1fcd98ab5b9863b077df3
Author: Jannis Pohlmann <jannis at xfce.org>
Date:   Tue Oct 27 18:26:01 2009 +0100

    Fix a bunch of compiler warnings.

 plugins/font-thumbnailer/font-thumbnailer.c     |    3 -
 plugins/pixbuf-thumbnailer/pixbuf-thumbnailer.c |    9 +-
 plugins/xdg-cache/xdg-cache-cache.c             |    1 -
 plugins/xdg-cache/xdg-cache-plugin.c            |    8 -
 po/tumbler.pot                                  |  169 -----------------------
 tumbler/tumbler-cache-plugin.c                  |   12 --
 tumbler/tumbler-file-info.c                     |    6 +-
 tumbler/tumbler-thumbnail.c                     |   13 --
 tumblerd/tumbler-cache-service.c                |    8 +-
 tumblerd/tumbler-group-scheduler.c              |    6 +-
 tumblerd/tumbler-lifo-scheduler.c               |    8 +-
 tumblerd/tumbler-registry.c                     |    3 -
 12 files changed, 8 insertions(+), 238 deletions(-)

diff --git a/plugins/font-thumbnailer/font-thumbnailer.c b/plugins/font-thumbnailer/font-thumbnailer.c
index 76ae117..6e347db 100644
--- a/plugins/font-thumbnailer/font-thumbnailer.c
+++ b/plugins/font-thumbnailer/font-thumbnailer.c
@@ -435,15 +435,12 @@ font_thumbnailer_create (TumblerAbstractThumbnailer *thumbnailer,
   TumblerThumbnail       *thumbnail;
   FontThumbnailer        *font_thumbnailer = FONT_THUMBNAILER (thumbnailer);
   const gchar            *uri;
-  GHashTable             *pixbufs;
   GdkPixbuf              *pixbuf;
   FT_Error                ft_error;
   FT_Face                 face;
   guint64                 mtime;
   GError                 *error = NULL;
   GFile                  *file;
-  GList                  *lp;
-  GList                  *thumbnails;
   gchar                  *error_msg;
   gchar                  *font_data;
   gsize                   length;
diff --git a/plugins/pixbuf-thumbnailer/pixbuf-thumbnailer.c b/plugins/pixbuf-thumbnailer/pixbuf-thumbnailer.c
index 83e272f..390d590 100644
--- a/plugins/pixbuf-thumbnailer/pixbuf-thumbnailer.c
+++ b/plugins/pixbuf-thumbnailer/pixbuf-thumbnailer.c
@@ -142,15 +142,10 @@ pixbuf_thumbnailer_create (TumblerAbstractThumbnailer *thumbnailer,
   TumblerImageData        data;
   TumblerThumbnail       *thumbnail;
   const gchar            *uri;
-  GHashTable             *pixbufs;
   GdkPixbuf              *source_pixbuf;
   GdkPixbuf              *pixbuf;
-  guint64                 mtime;
   GError                 *error = NULL;
   GFile                  *file;
-  GList                  *lp;
-  GList                  *thumbnails;
-  guint                   n;
 
   g_return_if_fail (IS_PIXBUF_THUMBNAILER (thumbnailer));
   g_return_if_fail (cancellable == NULL || G_IS_CANCELLABLE (cancellable));
@@ -215,7 +210,9 @@ pixbuf_thumbnailer_create (TumblerAbstractThumbnailer *thumbnailer,
   data.rowstride = gdk_pixbuf_get_rowstride (pixbuf);
   data.colorspace = (TumblerColorspace) gdk_pixbuf_get_colorspace (pixbuf);
 
-  tumbler_thumbnail_save_image_data (thumbnail, &data, mtime, NULL, &error);
+  tumbler_thumbnail_save_image_data (thumbnail, &data, 
+                                     tumbler_file_info_get_mtime (info), 
+                                     NULL, &error);
 
   if (error != NULL)
     {
diff --git a/plugins/xdg-cache/xdg-cache-cache.c b/plugins/xdg-cache/xdg-cache-cache.c
index 477ab35..dbc9e92 100644
--- a/plugins/xdg-cache/xdg-cache-cache.c
+++ b/plugins/xdg-cache/xdg-cache-cache.c
@@ -183,7 +183,6 @@ xdg_cache_cache_cleanup (TumblerCache *cache,
   gchar         *filename;
   gchar         *uri;
   GDir          *dir;
-  gint           n;
 
   g_return_if_fail (XDG_CACHE_IS_CACHE (cache));
   
diff --git a/plugins/xdg-cache/xdg-cache-plugin.c b/plugins/xdg-cache/xdg-cache-plugin.c
index 8faba4e..2e17fc0 100644
--- a/plugins/xdg-cache/xdg-cache-plugin.c
+++ b/plugins/xdg-cache/xdg-cache-plugin.c
@@ -71,11 +71,3 @@ tumbler_plugin_shutdown (void)
   g_message (_("Shutting down the Tumbler XDG cache plugin"));
 #endif
 }
-
-
-
-TumblerCache *
-tumbler_plugin_get_cache (void)
-{
-  return g_object_new (XDG_CACHE_TYPE_CACHE, NULL);
-}
diff --git a/po/tumbler.pot b/po/tumbler.pot
deleted file mode 100644
index b10c445..0000000
--- a/po/tumbler.pot
+++ /dev/null
@@ -1,169 +0,0 @@
-# SOME DESCRIPTIVE TITLE.
-# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
-# This file is distributed under the same license as the PACKAGE package.
-# FIRST AUTHOR <EMAIL at ADDRESS>, YEAR.
-#
-#, fuzzy
-msgid ""
-msgstr ""
-"Project-Id-Version: PACKAGE VERSION\n"
-"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-10-07 02:59+0200\n"
-"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
-"Last-Translator: FULL NAME <EMAIL at ADDRESS>\n"
-"Language-Team: LANGUAGE <LL at li.org>\n"
-"MIME-Version: 1.0\n"
-"Content-Type: text/plain; charset=CHARSET\n"
-"Content-Transfer-Encoding: 8bit\n"
-
-#: ../tumblerd/tumbler-cache-service.c:402
-#, c-format
-msgid "Another thumbnail cache service is already running"
-msgstr ""
-
-#: ../tumblerd/tumbler-group-scheduler.c:426
-#: ../tumblerd/tumbler-lifo-scheduler.c:379
-#, c-format
-msgid "No thumbnailer available for \"%s\""
-msgstr ""
-
-#: ../tumblerd/tumbler-service.c:409
-#, c-format
-msgid "Another generic thumbnailer is already running"
-msgstr ""
-
-#: ../tumblerd/tumbler-manager.c:230
-#, c-format
-msgid "Another thumbnailer manager is already running"
-msgstr ""
-
-#. set the application name. Translators: Don't translate "Tumbler".
-#: ../tumblerd/main.c:63
-msgid "Tumbler Thumbnailing Service"
-msgstr ""
-
-#: ../tumblerd/main.c:78
-#, c-format
-msgid "Failed to connect to the D-Bus session bus: %s"
-msgstr ""
-
-#: ../tumblerd/main.c:90
-#, c-format
-msgid "Failed to start the thumbnail cache service: %s"
-msgstr ""
-
-#: ../tumblerd/main.c:137
-#, c-format
-msgid "Failed to load specialized thumbnailers into the registry: %s"
-msgstr ""
-
-#: ../tumblerd/main.c:155
-#, c-format
-msgid "Failed to start the thumbnailer manager: %s"
-msgstr ""
-
-#: ../tumblerd/main.c:173
-#, c-format
-msgid "Failed to start the thumbnailer service: %s"
-msgstr ""
-
-#: ../tumbler/tumbler-enum-types.c:49 ../tumbler/tumbler-enum-types.c:73
-msgid "Invalid format"
-msgstr ""
-
-#: ../tumbler/tumbler-enum-types.c:50
-msgid "Normal"
-msgstr ""
-
-#: ../tumbler/tumbler-enum-types.c:51
-msgid "Large"
-msgstr ""
-
-#: ../tumbler/tumbler-enum-types.c:52
-msgid "Cropped"
-msgstr ""
-
-#: ../tumbler/tumbler-enum-types.c:74
-msgid "PNG"
-msgstr ""
-
-#: ../tumbler/tumbler-file-info.c:275
-#, c-format
-msgid "The file \"%s\" is a thumbnail itself"
-msgstr ""
-
-#: ../tumbler/tumbler-provider-plugin.c:135
-#, c-format
-msgid "Plugin \"%s\" lacks required symbols."
-msgstr ""
-
-#: ../tumbler/tumbler-provider-plugin.c:142
-#, c-format
-msgid "Failed to load plugin \"%s\": %s"
-msgstr ""
-
-#: ../plugins/pixbuf-thumbnailer/pixbuf-thumbnailer-plugin.c:57
-#: ../plugins/font-thumbnailer/font-thumbnailer-plugin.c:57
-#: ../plugins/xdg-cache/xdg-cache-plugin.c:58
-#, c-format
-msgid "Version mismatch: %s"
-msgstr ""
-
-#: ../plugins/pixbuf-thumbnailer/pixbuf-thumbnailer-plugin.c:62
-msgid "Initializing the Tumbler Pixbuf Thumbnailer plugin"
-msgstr ""
-
-#: ../plugins/pixbuf-thumbnailer/pixbuf-thumbnailer-plugin.c:79
-msgid "Shutting down the Tumbler Pixbuf Thumbnailer plugin"
-msgstr ""
-
-#: ../plugins/font-thumbnailer/font-thumbnailer-plugin.c:62
-msgid "Initializing the Tumbler Font Thumbnailer plugin"
-msgstr ""
-
-#: ../plugins/font-thumbnailer/font-thumbnailer-plugin.c:79
-msgid "Shutting down the Tumbler Font Thumbnailer plugin"
-msgstr ""
-
-#. there was an error in the freetype initialization, abort
-#: ../plugins/font-thumbnailer/font-thumbnailer.c:465
-#, c-format
-msgid "Could not initialize freetype: %s"
-msgstr ""
-
-#. there was an error, emit error signal
-#: ../plugins/font-thumbnailer/font-thumbnailer.c:489
-#, c-format
-msgid "Could not load file contents: %s"
-msgstr ""
-
-#. the font file could not be loaded, emit an error signal
-#: ../plugins/font-thumbnailer/font-thumbnailer.c:509
-#, c-format
-msgid "Could not open font file: %s"
-msgstr ""
-
-#. emit an error signal
-#: ../plugins/font-thumbnailer/font-thumbnailer.c:534
-#, c-format
-msgid "Could not set the character map: %s"
-msgstr ""
-
-#. emit an error signal
-#: ../plugins/font-thumbnailer/font-thumbnailer.c:565
-#, c-format
-msgid "Could not render glyphs: %s"
-msgstr ""
-
-#: ../plugins/xdg-cache/xdg-cache-thumbnail.c:373
-#, c-format
-msgid "Could not save thumbnail to \"%s\""
-msgstr ""
-
-#: ../plugins/xdg-cache/xdg-cache-plugin.c:63
-msgid "Initializing the Tumbler XDG cache plugin"
-msgstr ""
-
-#: ../plugins/xdg-cache/xdg-cache-plugin.c:81
-msgid "Shutting down the Tumbler XDG cache plugin"
-msgstr ""
diff --git a/tumbler/tumbler-cache-plugin.c b/tumbler/tumbler-cache-plugin.c
index 4a92b1c..7cfc27e 100644
--- a/tumbler/tumbler-cache-plugin.c
+++ b/tumbler/tumbler-cache-plugin.c
@@ -84,13 +84,6 @@ tumbler_cache_plugin_class_init (TumblerCachePluginClass *klass)
 
 
 static void
-tumbler_cache_plugin_cache_init (TumblerCacheIface *iface)
-{
-}
-
-
-
-static void
 tumbler_cache_plugin_init (TumblerCachePlugin *plugin)
 {
 }
@@ -100,7 +93,6 @@ tumbler_cache_plugin_init (TumblerCachePlugin *plugin)
 static void
 tumbler_cache_plugin_constructed (GObject *object)
 {
-  TumblerCachePlugin *plugin = TUMBLER_CACHE_PLUGIN (object);
 }
 
 
@@ -108,8 +100,6 @@ tumbler_cache_plugin_constructed (GObject *object)
 static void
 tumbler_cache_plugin_dispose (GObject *object)
 {
-  TumblerCachePlugin *plugin = TUMBLER_CACHE_PLUGIN (object);
-
   (*G_OBJECT_CLASS (tumbler_cache_plugin_parent_class)->dispose) (object);
 }
 
@@ -118,8 +108,6 @@ tumbler_cache_plugin_dispose (GObject *object)
 static void
 tumbler_cache_plugin_finalize (GObject *object)
 {
-  TumblerCachePlugin *plugin = TUMBLER_CACHE_PLUGIN (object);
-
   (*G_OBJECT_CLASS (tumbler_cache_plugin_parent_class)->finalize) (object);
 }
 
diff --git a/tumbler/tumbler-file-info.c b/tumbler/tumbler-file-info.c
index ece1bd1..3ab47eb 100644
--- a/tumbler/tumbler-file-info.c
+++ b/tumbler/tumbler-file-info.c
@@ -239,10 +239,6 @@ tumbler_file_info_load (TumblerFileInfo *info,
   GFileInfo    *file_info;
   GError       *err = NULL;
   GFile        *file;
-  GList        *cp;
-  GList        *lp;
-  GList        *thumbnails;
-  GList        *tp;
 
   g_return_val_if_fail (TUMBLER_IS_FILE_INFO (info), FALSE);
   g_return_val_if_fail (cancellable == NULL || G_IS_CANCELLABLE (cancellable), FALSE);
@@ -414,7 +410,7 @@ tumbler_file_info_array_copy (TumblerFileInfo **infos,
                               guint             length)
 {
   TumblerFileInfo **copy;
-  gint              n;
+  guint             n;
 
   g_return_val_if_fail (infos != NULL, NULL);
 
diff --git a/tumbler/tumbler-thumbnail.c b/tumbler/tumbler-thumbnail.c
index b8b497a..e6686c8 100644
--- a/tumbler/tumbler-thumbnail.c
+++ b/tumbler/tumbler-thumbnail.c
@@ -154,19 +154,6 @@ tumbler_thumbnail_save_file (TumblerThumbnail *thumbnail,
 
 
 
-TumblerCache *
-tumbler_thumbnail_get_cache (TumblerThumbnail *thumbnail)
-{
-  TumblerCache *cache = NULL;
-
-  g_return_val_if_fail (TUMBLER_IS_THUMBNAIL (thumbnail), NULL);
-
-  g_object_get (thumbnail, "cache", &cache, NULL);
-  return cache;
-}
-
-
-
 TumblerThumbnailFlavor *
 tumbler_thumbnail_get_flavor (TumblerThumbnail *thumbnail)
 {
diff --git a/tumblerd/tumbler-cache-service.c b/tumblerd/tumbler-cache-service.c
index 069c910..659a666 100644
--- a/tumblerd/tumbler-cache-service.c
+++ b/tumblerd/tumbler-cache-service.c
@@ -157,9 +157,7 @@ tumbler_cache_service_init (TumblerCacheService *service)
 static void
 tumbler_cache_service_constructed (GObject *object)
 {
-  TumblerProviderFactory *factory;
-  TumblerCacheService    *service = TUMBLER_CACHE_SERVICE (object);
-  GList                  *lp;
+  TumblerCacheService *service = TUMBLER_CACHE_SERVICE (object);
 
   /* chain up to parent classes */
   if (G_OBJECT_CLASS (tumbler_cache_service_parent_class)->constructed != NULL)
@@ -249,7 +247,6 @@ tumbler_cache_service_move_thread (gpointer data,
 {
   TumblerCacheService *service = TUMBLER_CACHE_SERVICE (user_data);
   MoveRequest         *request = data;
-  GList               *lp;
 
   g_return_if_fail (TUMBLER_IS_CACHE_SERVICE (service));
   g_return_if_fail (request != NULL);
@@ -274,7 +271,6 @@ tumbler_cache_service_copy_thread (gpointer data,
 {
   TumblerCacheService *service = TUMBLER_CACHE_SERVICE (user_data);
   CopyRequest         *request = data;
-  GList               *lp;
 
   g_return_if_fail (TUMBLER_IS_CACHE_SERVICE (service));
   g_return_if_fail (request != NULL);
@@ -299,7 +295,6 @@ tumbler_cache_service_delete_thread (gpointer data,
 {
   TumblerCacheService *service = TUMBLER_CACHE_SERVICE (user_data);
   DeleteRequest       *request = data;
-  GList               *lp;
 
   g_return_if_fail (TUMBLER_IS_CACHE_SERVICE (service));
   g_return_if_fail (request != NULL);
@@ -323,7 +318,6 @@ tumbler_cache_service_cleanup_thread (gpointer data,
 {
   TumblerCacheService *service = TUMBLER_CACHE_SERVICE (user_data);
   CleanupRequest      *request = data;
-  GList               *lp;
 
   g_return_if_fail (TUMBLER_IS_CACHE_SERVICE (service));
   g_return_if_fail (request != NULL);
diff --git a/tumblerd/tumbler-group-scheduler.c b/tumblerd/tumbler-group-scheduler.c
index b171384..22d160f 100644
--- a/tumblerd/tumbler-group-scheduler.c
+++ b/tumblerd/tumbler-group-scheduler.c
@@ -355,7 +355,7 @@ tumbler_group_scheduler_dequeue_request (TumblerSchedulerRequest *request,
                                          gpointer                 user_data)
 {
   guint handle = GPOINTER_TO_UINT (user_data);
-  gint  n;
+  guint n;
 
   g_return_if_fail (request != NULL);
   g_return_if_fail (handle != 0);
@@ -407,22 +407,18 @@ tumbler_group_scheduler_thread (gpointer data,
 {
   TumblerSchedulerRequest *request = data;
   TumblerGroupScheduler   *scheduler = user_data;
-  TumblerFileInfo         *info;
   const gchar            **uris;
   const gchar            **failed_uris;
   const gchar            **success_uris;
   UriError                *uri_error;
-  gboolean                 outdated;
   gboolean                 uri_needs_update;
   GString                 *message;
-  guint64                  mtime;
   GError                  *error = NULL;
   GList                   *iter;
   GList                   *uri_errors;
   GList                   *ready_uris;
   GList                   *cached_uris = NULL;
   GList                   *missing_uris = NULL;
-  GList                   *thumbnails;
   GList                   *lp;
   guint                    n;
   gint                     error_code;
diff --git a/tumblerd/tumbler-lifo-scheduler.c b/tumblerd/tumbler-lifo-scheduler.c
index 3620496..50cb183 100644
--- a/tumblerd/tumbler-lifo-scheduler.c
+++ b/tumblerd/tumbler-lifo-scheduler.c
@@ -331,7 +331,7 @@ tumbler_lifo_scheduler_dequeue_request (TumblerSchedulerRequest *request,
                                         gpointer                 user_data)
 {
   guint handle = GPOINTER_TO_UINT (user_data);
-  gint  n;
+  guint n;
 
   g_return_if_fail (request != NULL);
   g_return_if_fail (handle != 0);
@@ -355,17 +355,13 @@ tumbler_lifo_scheduler_thread (gpointer data,
 {
   TumblerSchedulerRequest *request = data;
   TumblerLifoScheduler    *scheduler = user_data;
-  TumblerFileInfo         *info;
   const gchar            **uris;
-  gboolean                 outdated;
   gboolean                 uri_needs_update;
-  guint64                  mtime;
   GError                  *error = NULL;
   GList                   *cached_uris = NULL;
   GList                   *missing_uris = NULL;
-  GList                   *thumbnails;
   GList                   *lp;
-  gint                     n;
+  guint                    n;
 
   g_return_if_fail (TUMBLER_IS_LIFO_SCHEDULER (scheduler));
   g_return_if_fail (request != NULL);
diff --git a/tumblerd/tumbler-registry.c b/tumblerd/tumbler-registry.c
index 2f5d9d2..b4f28d9 100644
--- a/tumblerd/tumbler-registry.c
+++ b/tumblerd/tumbler-registry.c
@@ -436,9 +436,6 @@ tumbler_registry_get_thumbnailer_array (TumblerRegistry    *registry,
   TumblerThumbnailer **thumbnailers = NULL;
   gchar               *hash_key;
   gchar               *scheme;
-  guint                num_mime_hints;
-  guint                num_thumbnailers;
-  guint                num_uris;
   guint                n;
 
   g_return_val_if_fail (TUMBLER_IS_REGISTRY (registry), NULL);



More information about the Xfce4-commits mailing list