Prevent crash when a non-existing userFcn is called from an existing library (MUSR-159)
This commit is contained in:
parent
f0d05d35cd
commit
f75194750c
@ -10,6 +10,7 @@ NEW the chi^2 calculation in single-histogram and asymmetry fits is parallelized
|
||||
if musrfit is built using a compiler supporting OpenMP (e.g. GCC >= 4.2)
|
||||
Using --disable-omp this feature can be disabled on the configure level.
|
||||
NEW any2many: force the user to define the exact NeXus ouput format (HDF4,HDF5,XML)
|
||||
FIXED crash in case a non-existing userFcn is called from an existing library (MUSR-159)
|
||||
FIXED slightly wrong chisq since the 0-bin entries were treated wrongly for scaled N0/Bkg data (MUSR-193)
|
||||
FIXED the evaluation of the LF depolarization functions (before numerous unnecessary calculations were performed)
|
||||
FIXED casting problem between uint32 and time_t for some compilers (MUSR-185)
|
||||
|
@ -1176,7 +1176,7 @@ Int_t PMsrHandler::WriteMsrFile(const Char_t *filename, map<UInt_t, TString> *co
|
||||
|
||||
// write FITPARAMETER block
|
||||
fout << "FITPARAMETER" << endl;
|
||||
fout << "# No Name Value Step Pos_Error Boundaries" << endl;
|
||||
fout << "# No Name Value Step Pos_Error Boundaries" << endl;
|
||||
|
||||
for (i = 0; i < fParam.size(); ++i) {
|
||||
if (commentsPAR) {
|
||||
|
@ -281,6 +281,18 @@ PTheory::PTheory(PMsrHandler *msrInfo, UInt_t runNo, const Bool_t hasParent) : f
|
||||
tokens = 0;
|
||||
}
|
||||
return;
|
||||
} else if (!TClass::GetDict(fUserFcnClassName.Data())) {
|
||||
cerr << endl << ">> PTheory::PTheory: **ERROR** user function class '" << fUserFcnClassName.Data() << "' not found.";
|
||||
cerr << endl << ">> " << fUserFcnSharedLibName.Data() << " loaded successfully, but no dictionary present.";
|
||||
cerr << endl << ">> See line no " << line->fLineNo;
|
||||
cerr << endl;
|
||||
fValid = false;
|
||||
// clean up
|
||||
if (tokens) {
|
||||
delete tokens;
|
||||
tokens = 0;
|
||||
}
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user