diff options
author | Max Kellermann <max@duempel.org> | 2008-12-29 17:32:53 +0100 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2008-12-29 17:32:53 +0100 |
commit | 4d3dd1ed2adbaf258157d78aaa2e99c46355952f (patch) | |
tree | 455df65bdccfa833908112b528d67fb8572f5993 /src/path.c | |
parent | 29500cedff72a469cb8b89f7de82ce9976dbd4f5 (diff) | |
download | mpd-4d3dd1ed2adbaf258157d78aaa2e99c46355952f.tar.gz mpd-4d3dd1ed2adbaf258157d78aaa2e99c46355952f.tar.xz mpd-4d3dd1ed2adbaf258157d78aaa2e99c46355952f.zip |
path: use GLib logging
Diffstat (limited to 'src/path.c')
-rw-r--r-- | src/path.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/src/path.c b/src/path.c index 1d1c3314d..e63f33b09 100644 --- a/src/path.c +++ b/src/path.c @@ -17,7 +17,6 @@ */ #include "path.h" -#include "log.h" #include "conf.h" #include "utils.h" #include "playlist.h" @@ -26,6 +25,9 @@ #include <string.h> +#undef G_LOG_DOMAIN +#define G_LOG_DOMAIN "path" + static char *fs_charset; char *fs_charset_to_utf8(char *dst, const char *str) @@ -71,7 +73,7 @@ void path_set_fs_charset(const char *charset) g_free(fs_charset); fs_charset = g_strdup(charset); - DEBUG("path_set_fs_charset: fs charset is: %s\n", fs_charset); + g_debug("path_set_fs_charset: fs charset is: %s", fs_charset); } const char *path_get_fs_charset(void) @@ -97,7 +99,7 @@ void path_global_init(void) if (charset) { path_set_fs_charset(charset); } else { - WARNING("setting filesystem charset to ISO-8859-1\n"); + g_message("setting filesystem charset to ISO-8859-1"); path_set_fs_charset("ISO-8859-1"); } } @@ -112,8 +114,8 @@ char *pfx_dir(char *dst, const char *pfx, const size_t pfx_len) { if (G_UNLIKELY((pfx_len + path_len + 1) >= MPD_PATH_MAX)) - FATAL("Cannot prefix '%s' to '%s', PATH_MAX: %d\n", - pfx, path, MPD_PATH_MAX); + g_error("Cannot prefix '%s' to '%s', PATH_MAX: %d", + pfx, path, MPD_PATH_MAX); /* memmove allows dst == path */ memmove(dst + pfx_len + 1, path, path_len + 1); |