add some asserts

This commit is contained in:
Josh Coalson
2001-03-28 22:14:43 +00:00
parent 801ec6028a
commit ae6e8b5157

View File

@@ -649,14 +649,17 @@ bool stream_decoder_read_frame_(FLAC__StreamDecoder *decoder, bool *got_a_frame)
/* no adjustment needed */ /* no adjustment needed */
break; break;
case FLAC__CHANNEL_ASSIGNMENT_LEFT_SIDE: case FLAC__CHANNEL_ASSIGNMENT_LEFT_SIDE:
assert(decoder->guts->frame.header.channels == 2);
if(channel == 1) if(channel == 1)
bps++; bps++;
break; break;
case FLAC__CHANNEL_ASSIGNMENT_RIGHT_SIDE: case FLAC__CHANNEL_ASSIGNMENT_RIGHT_SIDE:
assert(decoder->guts->frame.header.channels == 2);
if(channel == 0) if(channel == 0)
bps++; bps++;
break; break;
case FLAC__CHANNEL_ASSIGNMENT_MID_SIDE: case FLAC__CHANNEL_ASSIGNMENT_MID_SIDE:
assert(decoder->guts->frame.header.channels == 2);
if(channel == 1) if(channel == 1)
bps++; bps++;
break; break;