Skip to content

Commit 86043f3

Browse files
author
Ishan Goel
committed
Another change
1 parent 1a6a8c0 commit 86043f3

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

offline/packages/tpc/TpcClusterizer.cc

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1841,6 +1841,13 @@ void TpcClusterizer::makeChannelMask(hitMaskTpcSet &aMask, const std::string &db
18411841
int NChan = -1;
18421842
NChan = cdbttree->GetSingleIntValue(totalChannelsToMask);
18431843

1844+
if (NChan < 0)
1845+
{
1846+
std::cout << PHWHERE << "ERROR: Invalid or missing " << totalChannelsToMask
1847+
<< " for " << dbName << ". Masking disabled for this map." << std::endl;
1848+
return;
1849+
}
1850+
18441851
for (int i = 0; i < NChan; i++)
18451852
{
18461853
int Layer = cdbttree->GetIntValue(i, "layer");

0 commit comments

Comments
 (0)