aboutsummaryrefslogtreecommitdiffstats
path: root/src/decoder/MikmodDecoderPlugin.cxx
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2013-09-27 12:11:37 +0200
committerMax Kellermann <max@duempel.org>2013-09-27 12:11:37 +0200
commitc5d05ac0cf18dbd3d04534de240c437f8b07bd28 (patch)
tree5e69c019f69cc6f2f1d99c71448338d855bf4898 /src/decoder/MikmodDecoderPlugin.cxx
parent939003c1f1a8ed9f6e3fe677a63e1686fe35d929 (diff)
downloadmpd-c5d05ac0cf18dbd3d04534de240c437f8b07bd28.tar.gz
mpd-c5d05ac0cf18dbd3d04534de240c437f8b07bd28.tar.xz
mpd-c5d05ac0cf18dbd3d04534de240c437f8b07bd28.zip
DecoderCommand: convert to strictly-typed enum
Diffstat (limited to 'src/decoder/MikmodDecoderPlugin.cxx')
-rw-r--r--src/decoder/MikmodDecoderPlugin.cxx5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/decoder/MikmodDecoderPlugin.cxx b/src/decoder/MikmodDecoderPlugin.cxx
index f98b22a6d..78a26891a 100644
--- a/src/decoder/MikmodDecoderPlugin.cxx
+++ b/src/decoder/MikmodDecoderPlugin.cxx
@@ -148,7 +148,6 @@ mikmod_decoder_file_decode(struct decoder *decoder, const char *path_fs)
MODULE *handle;
int ret;
SBYTE buffer[MIKMOD_FRAME_SIZE];
- enum decoder_command cmd = DECODE_COMMAND_NONE;
path2 = g_strdup(path_fs);
handle = Player_Load(path2, 128, 0);
@@ -168,7 +167,9 @@ mikmod_decoder_file_decode(struct decoder *decoder, const char *path_fs)
decoder_initialized(decoder, audio_format, false, 0);
Player_Start(handle);
- while (cmd == DECODE_COMMAND_NONE && Player_Active()) {
+
+ DecoderCommand cmd = DecoderCommand::NONE;
+ while (cmd == DecoderCommand::NONE && Player_Active()) {
ret = VC_WriteBytes(buffer, sizeof(buffer));
cmd = decoder_data(decoder, nullptr, buffer, ret, 0);
}