From 44a69e2aee45348aeebd7ab3440ce9abc370312d Mon Sep 17 00:00:00 2001 From: Dhanya Maliakal Date: Wed, 19 Oct 2016 10:46:03 +0200 Subject: [PATCH] improved locking a bit --- slsDetectorSoftware/slsDetector/slsDetectorUtils.cpp | 5 +++-- .../slsDetectorAnalysis/postProcessing.cpp | 12 +++++------- 2 files changed, 8 insertions(+), 9 deletions(-) diff --git a/slsDetectorSoftware/slsDetector/slsDetectorUtils.cpp b/slsDetectorSoftware/slsDetector/slsDetectorUtils.cpp index d390c8398..495eaf210 100644 --- a/slsDetectorSoftware/slsDetector/slsDetectorUtils.cpp +++ b/slsDetectorSoftware/slsDetector/slsDetectorUtils.cpp @@ -171,7 +171,9 @@ int slsDetectorUtils::acquire(int delflag){ //resets frames caught in receiver if(receiver){ + pthread_mutex_lock(&mg); resetFramesCaught(); + pthread_mutex_unlock(&mg); } for(int im=0;im