fixed musrt0 crash for histogram number out of range (MUSR-157)
This commit is contained in:
parent
41f10b77c0
commit
7cb19dada8
@ -6,6 +6,7 @@
|
||||
|
||||
changes since 0.8.0
|
||||
===================================
|
||||
FIXED musrt0 crash for histogram number out of range (MUSR-157)
|
||||
FIXED fixes the inadequate attempt to use log max likelihood fit for asymmetry/non-muSR fit (MUSR-148)
|
||||
CHANGED less strict handling of empty FUNCTION block
|
||||
CHANGED cosmetics in the y-labelling (MUSR-154)
|
||||
|
@ -330,6 +330,12 @@ PMusrT0::PMusrT0(PMusrT0Data &data) : fMusrT0Data(data)
|
||||
return;
|
||||
}
|
||||
Int_t histoNo = fMusrT0Data.GetHistoNo(fMusrT0Data.GetHistoNoIdx())-1;
|
||||
if (histoNo >= (Int_t)rawRunData->GetNoOfHistos()) {
|
||||
cerr << endl << ">> PMusrT0::PMusrT0: **ERROR** found histogram number " << histoNo+1 << ", but only " << rawRunData->GetNoOfHistos() << " are present.";
|
||||
cerr << endl << ">> Please try to fix this first ..." << endl;
|
||||
fValid = false;
|
||||
return;
|
||||
}
|
||||
Int_t noOfBins = rawRunData->GetDataBin(histoNo)->size();
|
||||
Double_t start = -0.5;
|
||||
Double_t end = noOfBins - 0.5; // -0.5 is correct since the data start at 0.0
|
||||
|
Loading…
x
Reference in New Issue
Block a user