Open src/flac/decode.c, find write_callback() function and add

    return FLAC__STREAM_DECODER_WRITE_STATUS_ABORT;

to the beginning of the function. Decoding will fail with
the following message:

test.flac: ERROR while decoding data
             state = FLAC__STREAM_DECODER_READ_FRAME

As you can see, decoder state isn't quite correct.

One of the ways to fix this is in the attached patch.
After the patch flac writes:

test.flac: ERROR while decoding data
             state = FLAC__STREAM_DECODER_ABORTED

which is more logical.

Attachment: set_decoding_status.patch
Description: Binary data

_______________________________________________
flac-dev mailing list
flac-dev@xiph.org
http://lists.xiph.org/mailman/listinfo/flac-dev

Reply via email to