[grilo-plugins] filesystem: Print some errors as debug instead of warning
- From: Juan A. Suarez Romero <jasuarez src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [grilo-plugins] filesystem: Print some errors as debug instead of warning
- Date: Thu, 26 Apr 2012 17:44:18 +0000 (UTC)
commit 46e6ef5ec47540bcdd0434cbb1c832d066fea35b
Author: Juan A. Suarez Romero <jasuarez igalia com>
Date: Thu Apr 26 15:34:31 2012 +0000
filesystem: Print some errors as debug instead of warning
Those (unable to open a file, unable to read it) happens frequently, and it is
a common situation. Let's use warnings for things that should not happen.
Signed-off-by: Juan A. Suarez Romero <jasuarez igalia com>
src/media/filesystem/grl-filesystem.c | 12 ++++++------
1 files changed, 6 insertions(+), 6 deletions(-)
---
diff --git a/src/media/filesystem/grl-filesystem.c b/src/media/filesystem/grl-filesystem.c
index 8961af2..075ed36 100644
--- a/src/media/filesystem/grl-filesystem.c
+++ b/src/media/filesystem/grl-filesystem.c
@@ -309,8 +309,8 @@ file_is_valid_content (const gchar *path, gboolean fast)
file = g_file_new_for_path (path);
info = g_file_query_info (file, spec, 0, NULL, &error);
if (error) {
- GRL_WARNING ("Failed to get attributes for file '%s': %s",
- path, error->message);
+ GRL_DEBUG ("Failed to get attributes for file '%s': %s",
+ path, error->message);
g_error_free (error);
g_object_unref (file);
return FALSE;
@@ -352,7 +352,7 @@ set_container_childcount (const gchar *path,
GRL_DEBUG ("Opening directory '%s' for childcount", path);
dir = g_dir_open (path, 0, &error);
if (error) {
- GRL_WARNING ("Failed to open directory '%s': %s", path, error->message);
+ GRL_DEBUG ("Failed to open directory '%s': %s", path, error->message);
g_error_free (error);
return;
}
@@ -410,8 +410,8 @@ create_content (GrlMedia *content,
}
if (error) {
- GRL_WARNING ("Failed to get info for file '%s': %s", path,
- error->message);
+ GRL_DEBUG ("Failed to get info for file '%s': %s", path,
+ error->message);
if (!media) {
media = grl_media_new ();
grl_media_set_id (media, root_dir ? NULL : path);
@@ -584,7 +584,7 @@ produce_from_path (GrlMediaSourceBrowseSpec *bs, const gchar *path)
GRL_DEBUG ("Opening directory '%s'", path);
dir = g_dir_open (path, 0, &error);
if (error) {
- GRL_WARNING ("Failed to open directory '%s': %s", path, error->message);
+ GRL_DEBUG ("Failed to open directory '%s': %s", path, error->message);
bs->callback (bs->source, bs->browse_id, NULL, 0, bs->user_data, error);
g_error_free (error);
return;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]