Mercurial > mplayer.hg
changeset 21452:1f42a6aba8c9
Do not call usec_sleep when we are not supposed to sleep.
author | reimar |
---|---|
date | Sun, 03 Dec 2006 14:01:22 +0000 |
parents | 0446a5ea13f5 |
children | 9dd976e14792 |
files | input/input.c |
diffstat | 1 files changed, 3 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/input/input.c Sun Dec 03 13:12:29 2006 +0000 +++ b/input/input.c Sun Dec 03 14:01:22 2006 +0000 @@ -945,7 +945,8 @@ if(num_key_fd == 0) { - usec_sleep(time * 1000); + if (time) + usec_sleep(time * 1000); return MP_INPUT_NOTHING; } @@ -1026,7 +1027,7 @@ key_fds[i].flags |= MP_FD_DEAD; } } - if (!did_sleep) + if (time && !did_sleep) usec_sleep(time * 1000); return MP_INPUT_NOTHING; }