raster pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=5d6e30fae04a5d2aca3daf8eab5fe0d60b870330

commit 5d6e30fae04a5d2aca3daf8eab5fe0d60b870330
Author: Carsten Haitzler (Rasterman) <ras...@rasterman.com>
Date:   Fri Dec 13 21:15:01 2013 +0900

    fix fd leak in emotion webcam where fd of value 0 never closed
    
    fixes CID 1039175
---
 src/lib/emotion/emotion_webcam.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/lib/emotion/emotion_webcam.c b/src/lib/emotion/emotion_webcam.c
index 9a673d9..04756cb 100644
--- a/src/lib/emotion/emotion_webcam.c
+++ b/src/lib/emotion/emotion_webcam.c
@@ -143,7 +143,7 @@ _emotion_check_device(Emotion_Webcam *ew)
    eina_stringshare_del(ew->name);
    free(ew);
 #ifdef HAVE_V4L2
-   if (fd > 0) close(fd);
+   if (fd >= 0) close(fd);
 #endif
    return EINA_FALSE;
 }

-- 


Reply via email to