From 557cbf8f00f0fb534af6839fc7d69e0215fa64de Mon Sep 17 00:00:00 2001 From: Tom Trafford Date: Mon, 16 Mar 2020 11:20:55 +0000 Subject: [PATCH] Added check in desctructor to see if it had errored --- andorApp/src/andorCCD.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/andorApp/src/andorCCD.cpp b/andorApp/src/andorCCD.cpp index 39c1aa7..2364ff2 100755 --- a/andorApp/src/andorCCD.cpp +++ b/andorApp/src/andorCCD.cpp @@ -362,6 +362,7 @@ AndorCCD::AndorCCD(const char *portName, const char *installPath, int cameraSeri AndorCCD::~AndorCCD() { static const char *functionName = "~AndorCCD"; + asynStatus status; mExiting = true; this->lock(); @@ -378,9 +379,10 @@ AndorCCD::~AndorCCD() asynPrint(pasynUserSelf, ASYN_TRACE_ERROR, "%s:%s: %s\n", driverName, functionName, e.c_str()); + status = asynError; } this->unlock(); - while (mExited < 2) + while (mExited < 2 and status != asynError) epicsThreadSleep(0.2); }