conflict merged fix, lockin in stop and startandreadallnowait, r_restreamstop moved to stop

This commit is contained in:
Dhanya Maliakal
2017-12-08 11:45:29 +01:00
8 changed files with 28 additions and 100 deletions

View File

@ -1581,6 +1581,7 @@ int multiSlsDetector::startAcquisition(){
int multiSlsDetector::stopAcquisition(){
pthread_mutex_lock(&mg); // locks due to processing thread using threadpool when in use
int i=0;
int ret=OK,ret1=OK;
int posmin=0, posmax=thisMultiDetector->numberOfDetectors;
@ -1625,7 +1626,7 @@ int multiSlsDetector::stopAcquisition(){
}
*stoppedFlag=1;
pthread_mutex_unlock(&mg);
return ret;
};
@ -1874,7 +1875,7 @@ int* multiSlsDetector::startAndReadAll(){
int multiSlsDetector::startAndReadAllNoWait(){
pthread_mutex_lock(&mg); // locks due to processing thread using threadpool when in use
int i=0;
int ret=OK;
int posmin=0, posmax=thisMultiDetector->numberOfDetectors;
@ -1919,7 +1920,7 @@ int multiSlsDetector::startAndReadAllNoWait(){
ret=FAIL;
}
}
pthread_mutex_unlock(&mg);
return ret;
}
@ -6794,20 +6795,3 @@ bool multiSlsDetector::isAcquireReady() {
return OK;
}
int multiSlsDetector::restreamStopFromReceiver() {
int ret=OK, ret1;
for(int idet=0; idet<thisMultiDetector->numberOfDetectors; ++idet){
if (detectors[idet]) {
ret1=detectors[idet]->restreamStopFromReceiver();
if(detectors[idet]->getErrorMask())
setErrorMask(getErrorMask()|(1<<idet));
if (ret1!=OK)
ret=FAIL;
}
}
return ret;
}