tvi_v4l2: fix style in the uninit function

This commit is contained in:
Ben Boeckel 2016-08-04 23:10:50 -04:00 committed by wm4
parent fa7beaad1f
commit 0c4a73fa21
1 changed files with 6 additions and 4 deletions

View File

@ -1003,13 +1003,15 @@ static int uninit(priv_t *priv)
set_mute(priv, 1);
/* free memory and close device */
free(priv->map); priv->map = NULL;
free(priv->map);
priv->map = NULL;
priv->mapcount = 0;
if(priv->video_fd!=-1) {
if (priv->video_fd != -1) {
v4l2_close(priv->video_fd);
priv->video_fd = -1;
priv->video_fd = -1;
}
free(priv->video_dev); priv->video_dev = NULL;
free(priv->video_dev);
priv->video_dev = NULL;
if (priv->video_ringbuffer) {
for (int n = 0; n < priv->video_buffer_size_current; n++) {