QhullErrore=checkRunId();// Check for qhRunId after libqhull returns. For convenience, ought to be at end of libqhull try block
if(e.isDefined()){
e.logError();
}
}//maybeThrowQhullMessage
#//Helpers
//! Return QhullError for maybeThrowFromDestructor()
QhullErrorUsingLibQhull::
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 UsingLibQhull. Otherwise allocated a C++ object missed by qh_errexit
voidUsingLibQhull::
checkUsingLibQhull()const
{
if(s_using_libqhull){
if(s_qhull_output){
throwQhullError(10049,"Qhull error: UsingLibQhull already in use by QhullQh.runId %d",s_qhull_output->qhull_run_id);
}else{
throwQhullError(10050,"Qhull error: UsingLibQhull already in use. No s_qhull_output");