mirror of
https://gitlab.xiph.org/xiph/icecast-server.git
synced 2024-12-04 14:46:30 -05:00
Previous bugfix was incorrect, and made the problem worse, since it ensured
it would be triggered in certain cases, instead of merely making it dependant on previous values written to the variable in those cases. Fixes source disconnect on some (but very few) ogg bitstreams (the vast majority of my files play fine) svn path=/trunk/icecast/; revision=3978
This commit is contained in:
parent
e0054eb3ea
commit
b620ee918d
@ -148,12 +148,12 @@ void *source_main(void *arg)
|
|||||||
stats_event(source->mount, "type", source->format->format_description);
|
stats_event(source->mount, "type", source->format->format_description);
|
||||||
|
|
||||||
while (global.running == ICE_RUNNING) {
|
while (global.running == ICE_RUNNING) {
|
||||||
bytes = 0;
|
|
||||||
ret = source->format->get_buffer(source->format, NULL, 0, &refbuf);
|
ret = source->format->get_buffer(source->format, NULL, 0, &refbuf);
|
||||||
if(ret < 0) {
|
if(ret < 0) {
|
||||||
WARN0("Bad data from source");
|
WARN0("Bad data from source");
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
bytes = 1; /* Set to > 0 so that the post-loop check won't be tripped */
|
||||||
while (refbuf == NULL) {
|
while (refbuf == NULL) {
|
||||||
bytes = 0;
|
bytes = 0;
|
||||||
while (bytes <= 0) {
|
while (bytes <= 0) {
|
||||||
|
Loading…
Reference in New Issue
Block a user