From 29030b54c98b0aee65fbc10ebf7ba36bed98c02c Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Sat, 10 Aug 2013 18:02:44 +0200 Subject: util/Error: new error passing library Replaces GLib's GError. --- src/decoder/GmeDecoderPlugin.cxx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/decoder/GmeDecoderPlugin.cxx') 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 #include @@ -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; -- cgit v1.2.3