mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-04-25 07:40:03 +02:00
fixed a valgrind error
This commit is contained in:
parent
d3c807975f
commit
c3a9d3c342
@ -303,15 +303,16 @@ int postProcessingFuncs::initDataset(int *nModules,int *chPerMod,int modMask[],i
|
|||||||
totalChans=0;
|
totalChans=0;
|
||||||
|
|
||||||
|
|
||||||
|
if (nMods)
|
||||||
chansPerMod=new int [nMods];
|
chansPerMod=new int [nMods];
|
||||||
|
|
||||||
|
if (nMods)
|
||||||
moduleMask=new int [nMods];
|
moduleMask=new int [nMods];
|
||||||
|
|
||||||
nBins=0;
|
nBins=0;
|
||||||
if (angRadius && angOffset && angCenter && (binSize>0)) {
|
if (angRadius && angOffset && angCenter && (binSize>0)) {
|
||||||
// cout << "??????? creating angConv"<< endl;
|
// cout << "??????? creating angConv"<< endl;
|
||||||
|
if (nMods)
|
||||||
angConv=new angleConversionConstant*[nMods];
|
angConv=new angleConversionConstant*[nMods];
|
||||||
nBins=(int)(360./binSize)+1;
|
nBins=(int)(360./binSize)+1;
|
||||||
}
|
}
|
||||||
@ -380,11 +381,15 @@ int postProcessingFuncs::initDataset(int *nModules,int *chPerMod,int modMask[],i
|
|||||||
|
|
||||||
void postProcessingFuncs::deletePointers() {
|
void postProcessingFuncs::deletePointers() {
|
||||||
|
|
||||||
|
if(chansPerMod != NULL) {
|
||||||
delete [] chansPerMod;
|
delete [] chansPerMod;
|
||||||
chansPerMod=NULL;
|
chansPerMod=NULL;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (moduleMask != NULL) {
|
||||||
delete [] moduleMask;
|
delete [] moduleMask;
|
||||||
moduleMask=NULL;
|
moduleMask=NULL;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
if (badChannelMask) {
|
if (badChannelMask) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user