Commit 0969a86b authored by kraus's avatar kraus

avoid testing equality of floats

parent 7f6f2d6c
......@@ -1103,7 +1103,7 @@ unsigned int DataSink::rewindLinesSDDS(const std::string &fileName, double maxSP
linestream >> spos;
}
if ((spos > maxSPos && std::abs(spos - maxSPos) > 1e-6 * std::abs(spos - lastSPos)) || spos == lastSPos) break;
if ((spos - maxSPos) > 1e-20 * Physics::c || (spos - lastSPos) < 1e-20 * Physics::c) break;
allLines.pop();
......@@ -1120,4 +1120,4 @@ unsigned int DataSink::rewindLinesSDDS(const std::string &fileName, double maxSP
/***************************************************************************
* $RCSfile: DataSink.cpp,v $ $Author: adelmann $
* $Revision: 1.3 $ $Date: 2004/06/02 19:38:54 $
***************************************************************************/
\ No newline at end of file
***************************************************************************/
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment