Skip to content

Commit

Permalink
Fix index error in vector access.
Browse files Browse the repository at this point in the history
This was discovered by the windows debug build.
Refs #9643
  • Loading branch information
martyngigg committed Jul 29, 2014
1 parent 7627f22 commit ac1eafb
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions Code/Mantid/Framework/DataHandling/src/LoadVulcanCalFile.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -301,17 +301,20 @@ namespace DataHandling
continue;
}
}
maskss.close();

// Mask workspace index
std::ostringstream msg;
for (size_t i = 0; i < m_maskWS->getNumberHistograms(); ++i)
{
if (m_maskWS->readY(i)[0] > 0.5)
{
m_maskWS->maskWorkspaceIndex(i);
m_maskWS->dataY(i)[0] = 1.0;
g_log.notice() << "Mask workspace " << i << ", DataY = " << m_maskWS->readY(i)[i] << "\n";
}

maskss.close();
msg << "Mask workspace " << i << ", DataY = " << m_maskWS->readY(i)[0] << "\n";
}
g_log.notice(msg.str());

return;
}
Expand Down

0 comments on commit ac1eafb

Please sign in to comment.