diff options
author | Mauro Carvalho Chehab <mchehab+samsung@kernel.org> | 2018-09-20 16:39:23 -0300 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab+samsung@kernel.org> | 2018-09-20 16:39:23 -0300 |
commit | 75f8cc6781e3e834b27c5999c83258654655088b (patch) | |
tree | 84f5fbdf925f8323a9d7b354d480a9251e8f71f8 /src/v4l.c | |
parent | 8db7a8e712ed7b341914490ec3ed043d0adb9724 (diff) |
v4l: remove uneeded debug messages
There's no reason why printing a GUI message and a debug message
with the same contents.
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
Diffstat (limited to 'src/v4l.c')
-rw-r--r-- | src/v4l.c | 16 |
1 files changed, 5 insertions, 11 deletions
@@ -139,12 +139,10 @@ void camera_cap(cam_t *cam) /* Query device capabilities */ if (v4l2_ioctl(cam->dev, VIDIOC_QUERYCAP, &vid_cap) == -1) { - if (cam->debug == TRUE) { - fprintf(stderr, - "VIDIOC_QUERYCAP -- could not get camera capabilities, exiting.....\n"); - } - msg = g_strdup_printf(_("Could not connect to video device (%s).\nPlease check connection."), - cam->video_dev); + + msg = g_strdup_printf(_("Could not connect to video device (%s).\n" + "Please check connection. Error: %d"), + cam->video_dev, errno); error_dialog(msg); g_free(msg); exit(0); @@ -245,11 +243,7 @@ void camera_cap(cam_t *cam) } if (!(vid_cap.capabilities & V4L2_CAP_VIDEO_CAPTURE)) { - if (cam->debug == TRUE) { - fprintf(stderr, - "VIDIOC_QUERYCAP -- it is not a capture device, exiting.....\n"); - } - msg = g_strdup_printf(_("Could not connect to video device (%s).\nPlease check connection."), + msg = g_strdup_printf(_("Device %s is not a video capture device)."), cam->video_dev); error_dialog(msg); g_free(msg); |