mpv/osdep
wm4 0ba3760745 getch2: assume EOF when input file descriptor is invalid
When starting mpv with nohup, file descriptor 0 seems to be invalid for
some reason. (I'm not quite sure why it should be... /proc/pid/fd/0
seems to indicate it's just /dev/null, and using /dev/null explicitly
shows that it works just fine.)

select() will always immediately return, and this causes mpv to burn CPU
without reason. Fix this by treating it as EOF when read() returns
EBADF.

Also add EINVAL to this condition, because it seems like a good idea.

Conflicts:
	osdep/getch2.c
2013-11-02 19:05:04 +01:00
..
ar HIDRemote: remove OS X version checks 2013-09-17 20:44:54 +02:00
getch2-win.c core: move contents to mpvcore (2/2) 2013-08-06 22:52:31 +02:00
getch2.c getch2: assume EOF when input file descriptor is invalid 2013-11-02 19:05:04 +01:00
getch2.h core: cleanup more mp_fifo leftovers 2013-07-02 14:11:31 +02:00
glob-win.c osdep:/glob-win.c: reformat 2012-08-03 01:31:32 +02:00
glob.h
io.c win32: add getenv() UTF-8 variant 2013-09-18 19:08:51 +02:00
io.h path, win32: redo user configfile path handling 2013-09-18 19:08:51 +02:00
macosx_application.h cocoa: remove usage of mp_fifo 2013-07-03 22:25:45 +02:00
macosx_application.m cocoa: fix opening quarantined files on 10.9 with the bundle [2] 2013-11-02 19:02:03 +01:00
macosx_application_objc.h cocoa: fix race condition with input context creation 2013-11-02 19:01:39 +01:00
macosx_compat.h OSX: fix compilation with 10.7 SDK 2013-06-19 21:24:26 +02:00
macosx_events.h macosx: remove platform specific input queue 2013-08-13 23:02:43 +02:00
macosx_events.m macosx_events: fix modifiers handling with media keys 2013-09-05 07:38:37 +02:00
mpv.exe.manifest win32: edit resource files, in particular set CompanyName 2013-09-23 01:44:09 +02:00
mpv.rc Copyright, LICENSE: switch to GPL version 2 or later 2013-10-13 01:36:10 +02:00
numcores.c vd_ffmpeg: set thread count to number of cores on machine by default 2010-12-20 05:53:28 +02:00
numcores.h vd_ffmpeg: set thread count to number of cores on machine by default 2010-12-20 05:53:28 +02:00
path-macosx.m macosx: move bundle path stuff to path-macosx.m 2013-09-18 19:30:11 +02:00
path-win.c path, win32: redo user configfile path handling 2013-09-18 19:08:51 +02:00
path.h osdep/path: remove ifdefs 2013-09-18 19:42:19 +02:00
priority.c core: move contents to mpvcore (2/2) 2013-08-06 22:52:31 +02:00
priority.h
timer-darwin.c core: move contents to mpvcore (2/2) 2013-08-06 22:52:31 +02:00
timer-linux.c timer: refactor, add 64 bit timer function 2013-05-26 16:44:20 +02:00
timer-win2.c timer: use gettimeofday() on Windows 2013-05-26 16:44:20 +02:00
timer.c Replace calls to usec_sleep() 2013-05-26 16:44:20 +02:00
timer.h Replace calls to usec_sleep() 2013-05-26 16:44:20 +02:00