mirror of
https://github.com/mpv-player/mpv.git
synced 2025-12-28 05:33:14 +00:00
Do not queue empty cmd.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@25256 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
@@ -1248,7 +1248,7 @@ static mp_cmd_t *read_events(int time, int paused)
|
||||
|
||||
int
|
||||
mp_input_queue_cmd(mp_cmd_t* cmd) {
|
||||
if(cmd_queue_length >= CMD_QUEUE_SIZE)
|
||||
if(!cmd || cmd_queue_length >= CMD_QUEUE_SIZE)
|
||||
return 0;
|
||||
cmd_queue[cmd_queue_end] = cmd;
|
||||
cmd_queue_end = (cmd_queue_end + 1) % CMD_QUEUE_SIZE;
|
||||
|
||||
Reference in New Issue
Block a user