From 16497b0362244407a139479b6e15834cf709779c Mon Sep 17 00:00:00 2001 From: Stanislaw Halik Date: Sat, 2 Oct 2021 00:00:43 +0200 Subject: tracker/pt: fix rare crash due to QProcess use across threads This was caused by QProcess in video/ps3eye getting created from the UI thread, then recreated on the Point Tracker's thread. --- tracker-pt/ftnoir_tracker_pt.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'tracker-pt/ftnoir_tracker_pt.h') diff --git a/tracker-pt/ftnoir_tracker_pt.h b/tracker-pt/ftnoir_tracker_pt.h index fa3d94ad..50e51405 100644 --- a/tracker-pt/ftnoir_tracker_pt.h +++ b/tracker-pt/ftnoir_tracker_pt.h @@ -50,7 +50,6 @@ struct Tracker_PT : QThread, ITracker private: void run() override; - bool maybe_reopen_camera(); void set_fov(int value); pointer traits; @@ -74,6 +73,7 @@ private: std::atomic point_count { 0 }; std::atomic ever_success = false; + std::atomic reopen_camera_flag = true; mutable QMutex center_lock, data_lock; point_filter filter{s}; }; -- cgit v1.2.3