devilhorns pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=37d21a4729aec7044bce08640616d34faa60f940
commit 37d21a4729aec7044bce08640616d34faa60f940 Author: Chris Michael <[email protected]> Date: Mon Feb 2 11:59:27 2015 -0500 ecore-drm: Trap for failure to dup stdin Summary: If we fail to duplicate stdin, we should write out an error and exit appropriately. @fix Signed-off-by: Chris Michael <[email protected]> --- src/lib/ecore_drm/ecore_drm_tty.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/lib/ecore_drm/ecore_drm_tty.c b/src/lib/ecore_drm/ecore_drm_tty.c index f88d9f1..f9ea64c 100644 --- a/src/lib/ecore_drm/ecore_drm_tty.c +++ b/src/lib/ecore_drm/ecore_drm_tty.c @@ -152,7 +152,14 @@ ecore_drm_tty_open(Ecore_Drm_Device *dev, const char *name) if ((env = getenv("ECORE_DRM_TTY"))) snprintf(tty, sizeof(tty), "%s", env); else - dev->tty.fd = dup(STDIN_FILENO); + { + dev->tty.fd = dup(STDIN_FILENO); + if (dev->tty.fd < 0) + { + ERR("Could not dup stdin: %m"); + return EINA_FALSE; + } + } } else snprintf(tty, sizeof(tty), "%s", name); --
