Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Xiph.Org
flac
Commits
38e2927b
Commit
38e2927b
authored
Sep 23, 2003
by
Josh Coalson
Browse files
better handling of FLAC__STREAM_DECODER_READ_STATUS_END_OF_STREAM in read_callback_()
parent
45f26d10
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/libOggFLAC/stream_decoder.c
View file @
38e2927b
...
...
@@ -484,9 +484,13 @@ FLAC__StreamDecoderReadStatus read_callback_(const FLAC__StreamDecoder *unused,
}
ogg_bytes_read
=
ogg_bytes_to_read
;
if
(
decoder
->
private_
->
read_callback
(
decoder
,
(
FLAC__byte
*
)
oggbuf
,
&
ogg_bytes_read
,
decoder
->
private_
->
client_data
)
!=
FLAC__STREAM_DECODER_READ_STATUS_CONTINUE
)
{
decoder
->
protected_
->
state
=
OggFLAC__STREAM_DECODER_READ_ERROR
;
return
FLAC__STREAM_DECODER_READ_STATUS_ABORT
;
{
FLAC__StreamDecoderReadStatus
read_status
=
decoder
->
private_
->
read_callback
(
decoder
,
(
FLAC__byte
*
)
oggbuf
,
&
ogg_bytes_read
,
decoder
->
private_
->
client_data
);
if
(
read_status
!=
FLAC__STREAM_DECODER_READ_STATUS_CONTINUE
)
{
if
(
read_status
==
FLAC__STREAM_DECODER_READ_STATUS_ABORT
)
decoder
->
protected_
->
state
=
OggFLAC__STREAM_DECODER_READ_ERROR
;
return
read_status
;
}
}
if
(
ogg_sync_wrote
(
&
decoder
->
private_
->
ogg
.
sync_state
,
ogg_bytes_read
)
<
0
)
{
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment