summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorTodor Tomov <ttomov@mm-sol.com>2011-04-11 18:51:16 +0300
committerLaurent Pinchart <laurent.pinchart@ideasonboard.com>2011-04-12 16:23:53 +0200
commit42b3b3916e5a11d9bcd72bae9c721cd4e40c0cb4 (patch)
tree1db027d6d735ff717286a7a026bf86cb3342dff3 /src
parent5a5014feb7aeef1ccf8146e0a4fb53fc5d22bdcd (diff)
Reset file descriptor value after closing a subdev
After a subdev is closed set entity->fd to -1. Signed-off-by: Todor Tomov <ttomov@mm-sol.com>
Diffstat (limited to 'src')
-rw-r--r--src/subdev.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/subdev.c b/src/subdev.c
index 3960d05..f8ccfe3 100644
--- a/src/subdev.c
+++ b/src/subdev.c
@@ -51,6 +51,7 @@ int v4l2_subdev_open(struct media_entity *entity)
void v4l2_subdev_close(struct media_entity *entity)
{
close(entity->fd);
+ entity->fd = -1;
}
int v4l2_subdev_get_format(struct media_entity *entity,