Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/GStreamer/gst-plugins-good.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorJan Schmidt <jan@centricular.com>2018-06-20 18:36:42 +0300
committerTim-Philipp Müller <tim@centricular.com>2020-07-10 18:46:23 +0300
commit09d9ac2d2ead25a83f00d1bc21d686ffb64949b0 (patch)
treec79595769510e05e64cc27dc77c87d95d5c27886 /sys
parent39a026760d26050f2f9060c0fc083241b932d9c4 (diff)
rpicamsrc: Don't destroy the camera component on startup error
Just disable the camera component when it fails to start. The most common reason is that the camera device is already in use, and if we just disable the mmal component correct cleanup will happen later
Diffstat (limited to 'sys')
-rw-r--r--sys/rpicamsrc/RaspiCapture.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/sys/rpicamsrc/RaspiCapture.c b/sys/rpicamsrc/RaspiCapture.c
index cae5cf61c..a7d72a0e1 100644
--- a/sys/rpicamsrc/RaspiCapture.c
+++ b/sys/rpicamsrc/RaspiCapture.c
@@ -1268,9 +1268,8 @@ raspi_capture_set_format_and_start(RASPIVID_STATE *state)
return status;
error:
-
if (camera)
- mmal_component_destroy(camera);
+ mmal_component_disable(camera);
return status;
}