diff options
Diffstat (limited to 'tracker-pt')
-rw-r--r-- | tracker-pt/ftnoir_tracker_pt.cpp | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/tracker-pt/ftnoir_tracker_pt.cpp b/tracker-pt/ftnoir_tracker_pt.cpp index a85e3bc0..8192a76d 100644 --- a/tracker-pt/ftnoir_tracker_pt.cpp +++ b/tracker-pt/ftnoir_tracker_pt.cpp @@ -32,9 +32,13 @@ Tracker_PT::~Tracker_PT() { set_command(ABORT); wait(); - delete video_widget; + if (video_widget) + delete video_widget; video_widget = NULL; - if (video_frame->layout()) delete video_frame->layout(); + if (video_frame) + { + if (video_frame->layout()) delete video_frame->layout(); + } // fast start/stop causes breakage portable::sleep(1000); camera.stop(); |