Skip to content

Commit

Permalink
Fix crash due to incorrect loop bounds in add-spatter.
Browse files Browse the repository at this point in the history
This caused a buffer overrun bug if an ADD_SPATTER
reaction had any non-improvement outputs.
  • Loading branch information
angavrilov committed Aug 22, 2013
1 parent df2e04d commit 70a2ab9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion plugins/add-spatter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -378,7 +378,7 @@ static bool find_reactions(color_ostream &out)
parse_product(out, out_prod.back(), it->second.react, itprod);
}

for (size_t i = 0; i < prod.size(); i++)
for (size_t i = 0; i < out_prod.size(); i++)
{
if (out_prod[i].isValid())
products[out_prod[i].product] = &out_prod[i];
Expand Down

0 comments on commit 70a2ab9

Please sign in to comment.