aboutsummaryrefslogtreecommitdiffstats
path: root/src/decoder/FLACCommon.cxx
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2012-10-02 19:27:30 +0200
committerMax Kellermann <max@duempel.org>2012-10-02 19:59:49 +0200
commitebd90dbb1a265d1a1c38252891cfe862a0d8a9b9 (patch)
tree876c92a56ebde52f489af9732957aaf70ad629c4 /src/decoder/FLACCommon.cxx
parentc9e700f07928b4a7dd34b8fdd2a00c226fd9b0b4 (diff)
downloadmpd-ebd90dbb1a265d1a1c38252891cfe862a0d8a9b9.tar.gz
mpd-ebd90dbb1a265d1a1c38252891cfe862a0d8a9b9.tar.xz
mpd-ebd90dbb1a265d1a1c38252891cfe862a0d8a9b9.zip
decoder/flac: move callbacks to class FLACInput
Diffstat (limited to '')
-rw-r--r--src/decoder/FLACCommon.cxx12
1 files changed, 2 insertions, 10 deletions
diff --git a/src/decoder/FLACCommon.cxx b/src/decoder/FLACCommon.cxx
index ed9245100..97743f332 100644
--- a/src/decoder/FLACCommon.cxx
+++ b/src/decoder/FLACCommon.cxx
@@ -36,7 +36,8 @@ extern "C" {
flac_data::flac_data(struct decoder *_decoder,
struct input_stream *_input_stream)
- :initialized(false), unsupported(false),
+ :FLACInput(_input_stream, _decoder),
+ initialized(false), unsupported(false),
total_frames(0), first_frame(0), next_frame(0), position(0),
decoder(_decoder), input_stream(_input_stream),
tag(nullptr)
@@ -132,15 +133,6 @@ void flac_metadata_common_cb(const FLAC__StreamMetadata * block,
}
}
-void flac_error_common_cb(const FLAC__StreamDecoderErrorStatus status,
- struct flac_data *data)
-{
- if (decoder_get_command(data->decoder) == DECODE_COMMAND_STOP)
- return;
-
- g_warning("%s", FLAC__StreamDecoderErrorStatusString[status]);
-}
-
/**
* This function attempts to call decoder_initialized() in case there
* was no STREAMINFO block. This is allowed for nonseekable streams,