diff --git a/src/classes/PRunSingleHisto.cpp b/src/classes/PRunSingleHisto.cpp index 2881a32d..020c31e6 100644 --- a/src/classes/PRunSingleHisto.cpp +++ b/src/classes/PRunSingleHisto.cpp @@ -1555,7 +1555,7 @@ void PRunSingleHisto::EstimateN0() if (paramNo > 10000) // i.e. fun or map return; - // still missing: set this value in the parameters + // get the parameters PMsrParamList *param = fMsrInfo->GetMsrParamList(); assert(param); @@ -1564,6 +1564,11 @@ void PRunSingleHisto::EstimateN0() return; } + // check if N0 is fixed. If this is the case, do NOT estimate N0 + if (param->at(paramNo-1).fStep == 0.0) // N0 parameter fixed + return; + + // check that 'backgr.fit' in the msr-file run block is indeed a parameter number. // in case it is a function, nothing will be done. Int_t paramNoBkg = fRunInfo->GetBkgFitParamNo(); diff --git a/src/musredit/PTextEdit.cpp b/src/musredit/PTextEdit.cpp index 0d4fb735..d22e4294 100644 --- a/src/musredit/PTextEdit.cpp +++ b/src/musredit/PTextEdit.cpp @@ -2186,6 +2186,9 @@ void PTextEdit::musrView() cmd = str + " \""; str = *fFilenames.find( currentEditor() ); + int pos = str.lastIndexOf("/"); + if (pos != -1) + str.remove(0, pos+1); QString numStr; numStr.setNum(fAdmin->getTimeout()); cmd += str + "\" --timeout " + numStr; @@ -2194,6 +2197,10 @@ void PTextEdit::musrView() cmd += " &"; int status=system(cmd.toLatin1()); + + if (status != 0) { + cerr << "**WARNING** musrView: something went wrong ..." << endl; + } } //---------------------------------------------------------------------------------------------------- diff --git a/src/musredit_qt5/PTextEdit.cpp b/src/musredit_qt5/PTextEdit.cpp index 6069529e..a31bc17e 100644 --- a/src/musredit_qt5/PTextEdit.cpp +++ b/src/musredit_qt5/PTextEdit.cpp @@ -2184,6 +2184,9 @@ void PTextEdit::musrView() cmd = str + " \""; str = *fFilenames.find( currentEditor() ); + int pos = str.lastIndexOf("/"); + if (pos != -1) + str.remove(0, pos+1); QString numStr; numStr.setNum(fAdmin->getTimeout()); cmd += str + "\" --timeout " + numStr; @@ -2192,6 +2195,10 @@ void PTextEdit::musrView() cmd += " &"; int status=system(cmd.toLatin1()); + + if (status != 0) { + cerr << "**WARNING** musrView: something went wrong ..." << endl; + } } //----------------------------------------------------------------------------------------------------