QhullErrore=checkRunId();// Check for qhRunId after qhulllib returns. For convenience, ought to be at end of qhulllib try block
if(e.defined()){
e.logError();
}
}//maybeThrowQhullMessage
#//Helpers
//! Return QhullError for maybeThrowFromDestructor()
QhullErrorUsingQhullLib::
checkRunId()const
{
// Predeclaring QhullError results in four copy constructors, none used here
#if qh_QHpointer
if(qh_qh){// 0 if ~Qhull
if(my_qhull->qhull_run_id!=qhrun_id){
returnQhullError(10047,"Qhull internal error: Global state (qh_qh, run_id %d) changed. Should be runId %d. Another thread?",qhrun_id,my_qhull->qhull_run_id);
returnQhullError(10048,"Qhull internal error: Global state (qh_qh, run_id %d) changed. Should be runId %d. Another thread?",qhrun_id,my_qhull->qhull_run_id);
}
#endif
returnQhullError();
}//checkRunId
//! Can not embed UsingQhullLib. Otherwise allocated a C++ object missed by qh_errexit
voidUsingQhullLib::
checkUsingQhullLib()const
{
if(s_using_qhulllib){
if(s_qhull_output){
throwQhullError(10049,"Qhull error: UsingQhullLib already in use by QhullQh.runId %d",s_qhull_output->qhull_run_id);
}else{
throwQhullError(10050,"Qhull error: UsingQhullLib already in use. No s_qhull_output");