From c5d05ac0cf18dbd3d04534de240c437f8b07bd28 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Fri, 27 Sep 2013 12:11:37 +0200 Subject: DecoderCommand: convert to strictly-typed enum --- src/decoder/DsdiffDecoderPlugin.cxx | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) (limited to 'src/decoder/DsdiffDecoderPlugin.cxx') diff --git a/src/decoder/DsdiffDecoderPlugin.cxx b/src/decoder/DsdiffDecoderPlugin.cxx index 49b0c601d..80b88a2c2 100644 --- a/src/decoder/DsdiffDecoderPlugin.cxx +++ b/src/decoder/DsdiffDecoderPlugin.cxx @@ -403,17 +403,16 @@ dsdiff_decode_chunk(struct decoder *decoder, struct input_stream *is, if (lsbitfirst) bit_reverse_buffer(buffer, buffer + nbytes); - enum decoder_command cmd = - decoder_data(decoder, is, buffer, nbytes, 0); + const auto cmd = decoder_data(decoder, is, buffer, nbytes, 0); switch (cmd) { - case DECODE_COMMAND_NONE: + case DecoderCommand::NONE: break; - case DECODE_COMMAND_START: - case DECODE_COMMAND_STOP: + case DecoderCommand::START: + case DecoderCommand::STOP: return false; - case DECODE_COMMAND_SEEK: + case DecoderCommand::SEEK: /* Not implemented yet */ decoder_seek_error(decoder); -- cgit v1.2.3