Skip to content
Snippets Groups Projects
Commit 3f4046ee authored by Mark OLESEN's avatar Mark OLESEN
Browse files

BUG: index error when parsing integers from prefix_rayId_lambdaId

parent 5e7a2917
No related merge requests found
......@@ -530,11 +530,11 @@ void Foam::radiation::fvDOM::setRayIdLambdaId
label& lambdaId
) const
{
// assuming name is in the form: CHARS_rayId_lambdaId
// Assuming name is in the form: CHARS_rayId_lambdaId
const auto i1 = name.find('_');
const auto i2 = name.rfind('_');
const auto i2 = name.find('_', i1+1);
rayId = readLabel(name.substr(i1+1, i2-1));
rayId = readLabel(name.substr(i1+1, i2-i1-1));
lambdaId = readLabel(name.substr(i2+1));
}
......
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