-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ao: not start AO when receiving EOF data. #13243
base: master
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -656,10 +656,14 @@ static bool ao_play_data(struct ao *ao) | |
MP_STATS(ao, "end ao fill"); | ||
|
||
if (!p->streaming) { | ||
MP_VERBOSE(ao, "starting AO\n"); | ||
ao->driver->start(ao); | ||
p->streaming = true; | ||
state.playing = true; | ||
if (got_eof) { | ||
MP_WARN(ao, "Error starting AO with EOF data.\n"); | ||
} else { | ||
MP_VERBOSE(ao, "starting AO\n"); | ||
ao->driver->start(ao); | ||
p->streaming = true; | ||
state.playing = true; | ||
} | ||
} | ||
} | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Thinking about this further you can see that this code only runs if there are samples to play. What I think might be broken is the logic that calls ao_drain or ao_reset when appropriate. (In your log it seems it is never called.) |
||
|
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure this makes sense.
Where exactly is the error in this case? Since the user is informed, what can he do to resolve it?