aboutsummaryrefslogtreecommitdiffstats
path: root/src/input/ArchiveInputPlugin.cxx
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2013-09-27 22:31:24 +0200
committerMax Kellermann <max@duempel.org>2013-10-02 08:57:55 +0200
commit060814daa83f6a94f5934464ae42a406c5c7e947 (patch)
treef636ec6cdbb8e52fda6db987d2a28fc73c7b94b4 /src/input/ArchiveInputPlugin.cxx
parentc53492a76a8a05825e1c7f699c05645eee891199 (diff)
downloadmpd-060814daa83f6a94f5934464ae42a406c5c7e947.tar.gz
mpd-060814daa83f6a94f5934464ae42a406c5c7e947.tar.xz
mpd-060814daa83f6a94f5934464ae42a406c5c7e947.zip
Log: new logging library API
Prepare to migrate away from GLib. Currently, we're still using GLib as a backend.
Diffstat (limited to '')
-rw-r--r--src/input/ArchiveInputPlugin.cxx10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/input/ArchiveInputPlugin.cxx b/src/input/ArchiveInputPlugin.cxx
index 025b25fef..08e1cabfe 100644
--- a/src/input/ArchiveInputPlugin.cxx
+++ b/src/input/ArchiveInputPlugin.cxx
@@ -25,9 +25,13 @@
#include "ArchiveFile.hxx"
#include "InputPlugin.hxx"
#include "util/Error.hxx"
+#include "util/Domain.hxx"
+#include "Log.hxx"
#include <glib.h>
+static constexpr Domain archive_domain("archive");
+
/**
* select correct archive plugin to handle the input stream
* may allow stacking of archive plugins. for example for handling
@@ -51,7 +55,8 @@ input_archive_open(const char *pathname,
pname = g_strdup(pathname);
// archive_lookup will modify pname when true is returned
if (!archive_lookup(pname, &archive, &filename, &suffix)) {
- g_debug("not an archive, lookup %s failed\n", pname);
+ FormatDebug(archive_domain,
+ "not an archive, lookup %s failed", pname);
g_free(pname);
return NULL;
}
@@ -59,7 +64,8 @@ input_archive_open(const char *pathname,
//check which archive plugin to use (by ext)
arplug = archive_plugin_from_suffix(suffix);
if (!arplug) {
- g_warning("can't handle archive %s\n",archive);
+ FormatWarning(archive_domain,
+ "can't handle archive %s", archive);
g_free(pname);
return NULL;
}