summaryrefslogtreecommitdiff
path: root/src/cam/main.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/cam/main.cpp')
-rw-r--r--src/cam/main.cpp12
1 files changed, 11 insertions, 1 deletions
diff --git a/src/cam/main.cpp b/src/cam/main.cpp
index a567a7cc..b13230c3 100644
--- a/src/cam/main.cpp
+++ b/src/cam/main.cpp
@@ -371,7 +371,17 @@ int CamApp::run()
if (options_.isSet(OptCapture)) {
CameraSession session(camera_, config_.get());
session.captureDone.connect(this, &CamApp::captureDone);
- return session.run(options_);
+
+ ret = session.start(options_);
+ if (ret) {
+ std::cout << "Failed to start camera session" << std::endl;
+ return ret;
+ }
+
+ loop_.exec();
+
+ session.stop();
+ return 0;
}
if (options_.isSet(OptMonitor)) {