aboutsummaryrefslogtreecommitdiffstats
path: root/src/decoder/GmeDecoderPlugin.cxx
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2013-08-10 18:02:44 +0200
committerMax Kellermann <max@duempel.org>2013-09-04 18:14:22 +0200
commit29030b54c98b0aee65fbc10ebf7ba36bed98c02c (patch)
tree79766830b55ebca38ddbce84d8d548227eedb69e /src/decoder/GmeDecoderPlugin.cxx
parentc9fcc7f14860777458153eb2d13c773ccfa1daa2 (diff)
downloadmpd-29030b54c98b0aee65fbc10ebf7ba36bed98c02c.tar.gz
mpd-29030b54c98b0aee65fbc10ebf7ba36bed98c02c.tar.xz
mpd-29030b54c98b0aee65fbc10ebf7ba36bed98c02c.zip
util/Error: new error passing library
Replaces GLib's GError.
Diffstat (limited to 'src/decoder/GmeDecoderPlugin.cxx')
-rw-r--r--src/decoder/GmeDecoderPlugin.cxx8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/decoder/GmeDecoderPlugin.cxx b/src/decoder/GmeDecoderPlugin.cxx
index d8edbe4cb..006161c78 100644
--- a/src/decoder/GmeDecoderPlugin.cxx
+++ b/src/decoder/GmeDecoderPlugin.cxx
@@ -23,6 +23,7 @@
#include "CheckAudioFormat.hxx"
#include "TagHandler.hxx"
#include "util/UriUtil.hxx"
+#include "util/Error.hxx"
#include <glib.h>
#include <assert.h>
@@ -152,13 +153,12 @@ gme_file_decode(struct decoder *decoder, const char *path_fs)
/* initialize the MPD decoder */
- GError *error = nullptr;
+ Error error;
AudioFormat audio_format;
if (!audio_format_init_checked(audio_format, GME_SAMPLE_RATE,
SampleFormat::S16, GME_CHANNELS,
- &error)) {
- g_warning("%s", error->message);
- g_error_free(error);
+ error)) {
+ g_warning("%s", error.GetMessage());
gme_free_info(ti);
gme_delete(emu);
return;