client API: remove some dead code

This was for the "suspend" API, which has been removed (turned into
stubs) a long time ago.
This commit is contained in:
wm4 2019-12-17 23:11:15 +01:00
parent e75d28effd
commit 13dff3073d
1 changed files with 0 additions and 6 deletions

View File

@ -126,7 +126,6 @@ struct mpv_handle {
uint64_t event_mask;
bool queued_wakeup;
int suspend_count;
mpv_event *events; // ringbuffer of max_events entries
int max_events; // allocated number of entries in events
@ -831,11 +830,6 @@ mpv_event *mpv_wait_event(mpv_handle *ctx, double timeout)
event->event_id = MPV_EVENT_QUEUE_OVERFLOW;
break;
}
// This will almost surely lead to a deadlock. (Polling is still ok.)
if (ctx->suspend_count && timeout > 0) {
MP_ERR(ctx, "attempting to wait while core is suspended");
break;
}
if (ctx->num_events) {
*event = ctx->events[ctx->first_event];
ctx->first_event = (ctx->first_event + 1) % ctx->max_events;