diff options
author | Josh Coalson <jcoalson@users.sourceforce.net> | 2006-11-09 06:58:26 +0000 |
---|---|---|
committer | Josh Coalson <jcoalson@users.sourceforce.net> | 2006-11-09 06:58:26 +0000 |
commit | a586226fda6f6a3781adb0f117554917b1e945ea (patch) | |
tree | 7e0fc8d36a48b685aa2fff79a114d761669d71f8 /src/test_libFLAC++/encoders.cpp | |
parent | 38bf3e6ca9fa103e5ce2bc8ee922d6e36e457298 (diff) | |
download | flac-a586226fda6f6a3781adb0f117554917b1e945ea.tar.gz |
add a boolean return value to FLAC__stream_encoder_finish() that signals a verify mismatch
Diffstat (limited to 'src/test_libFLAC++/encoders.cpp')
-rw-r--r-- | src/test_libFLAC++/encoders.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/test_libFLAC++/encoders.cpp b/src/test_libFLAC++/encoders.cpp index 14364988..acb1ec37 100644 --- a/src/test_libFLAC++/encoders.cpp +++ b/src/test_libFLAC++/encoders.cpp @@ -473,7 +473,11 @@ static bool test_stream_encoder(Layer layer, bool is_ogg) printf("OK\n"); printf("testing finish()... "); - encoder->finish(); + if(!encoder->finish()) { + FLAC::Encoder::Stream::State state = encoder->get_state(); + printf("FAILED, returned false, state = %u (%s)\n", (unsigned)((::FLAC__StreamEncoderState)state), state.as_cstring()); + return false; + } printf("OK\n"); printf("freeing encoder instance... "); |