diff --git a/configure.in b/configure.in index 29b3ee3c..c5d89bec 100644 --- a/configure.in +++ b/configure.in @@ -273,7 +273,7 @@ fi CFLAGS="$OUR_CFLAGS_HEAD $CFLAGS" CXXFLAGS="$OUR_CFLAGS_HEAD $CXXFLAGS" -#@@@@@@ +#@@@ AM_CONDITIONAL(FLaC__HAS_AS__TEMPORARILY_DISABLED, test "yes" = "no") AM_CONDITIONAL(FLaC__HAS_GAS__TEMPORARILY_DISABLED, test "yes" = "no") diff --git a/src/flac/decode.c b/src/flac/decode.c index 834841cf..fec97d69 100644 --- a/src/flac/decode.c +++ b/src/flac/decode.c @@ -975,7 +975,7 @@ FLAC__StreamDecoderWriteStatus write_callback(const FLAC__StreamDecoder *decoder if(shift && !decoder_session->replaygain.apply) { for(wide_sample = 0; wide_sample < wide_samples; wide_sample++) for(channel = 0; channel < channels; channel++) - /*@@@@@@bad un-const:fix@@@@@@*/((FLAC__int32**)buffer)[channel][wide_sample] <<= shift; + ((FLAC__int32**)buffer)[channel][wide_sample] <<= shift;/*@@@@@@un-const'ing the buffer is hacky but safe*/ } if(decoder_session->replaygain.apply) { bytes_to_write = FLAC__replaygain_synthesis__apply_gain( diff --git a/src/libFLAC/stream_encoder.c b/src/libFLAC/stream_encoder.c index 123708cd..5657778a 100644 --- a/src/libFLAC/stream_encoder.c +++ b/src/libFLAC/stream_encoder.c @@ -1115,11 +1115,6 @@ FLAC_API FLAC__StreamEncoderInitStatus FLAC__stream_encoder_init_FILE(FLAC__Stre FLAC__ASSERT(0 != encoder); FLAC__ASSERT(0 != file); - /* - * To make sure that our file does not go unclosed after an error, we - * must assign the FILE pointer before any further error can occur in - * this routine. - */ if(encoder->protected_->state != FLAC__STREAM_ENCODER_UNINITIALIZED) return FLAC__STREAM_ENCODER_INIT_STATUS_ALREADY_INITIALIZED; @@ -1129,6 +1124,11 @@ FLAC_API FLAC__StreamEncoderInitStatus FLAC__stream_encoder_init_FILE(FLAC__Stre return FLAC__STREAM_ENCODER_INIT_STATUS_ENCODER_ERROR; } + /* + * To make sure that our file does not go unclosed after an error, we + * must assign the FILE pointer before any further error can occur in + * this routine. + */ if(file == stdout) file = get_binary_stdout_(); /* just to be safe */