aboutsummaryrefslogtreecommitdiffstats
path: root/src/decoder/_flac_common.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/decoder/_flac_common.c')
-rw-r--r--src/decoder/_flac_common.c17
1 files changed, 2 insertions, 15 deletions
diff --git a/src/decoder/_flac_common.c b/src/decoder/_flac_common.c
index fc42e5913..bab3995f0 100644
--- a/src/decoder/_flac_common.c
+++ b/src/decoder/_flac_common.c
@@ -139,26 +139,13 @@ void flac_metadata_common_cb(const FLAC__StreamMetadata * block,
}
}
-void flac_error_common_cb(const char *plugin,
- const FLAC__StreamDecoderErrorStatus status,
+void flac_error_common_cb(const FLAC__StreamDecoderErrorStatus status,
struct flac_data *data)
{
if (decoder_get_command(data->decoder) == DECODE_COMMAND_STOP)
return;
- switch (status) {
- case FLAC__STREAM_DECODER_ERROR_STATUS_LOST_SYNC:
- g_warning("%s lost sync\n", plugin);
- break;
- case FLAC__STREAM_DECODER_ERROR_STATUS_BAD_HEADER:
- g_warning("bad %s header\n", plugin);
- break;
- case FLAC__STREAM_DECODER_ERROR_STATUS_FRAME_CRC_MISMATCH:
- g_warning("%s crc mismatch\n", plugin);
- break;
- default:
- g_warning("unknown %s error\n", plugin);
- }
+ g_warning("%s", FLAC__StreamDecoderErrorStatusString[status]);
}
/**