hyrise / hyrise-v1

HYRISE In-Memory Hybrid Storage Engine (archived, now developed in hyrise/hyrise repo)
https://github.com/hyrise/hyrise
MIT License
89 stars 44 forks source link

Layouter: Iteration beyond size #214

Open bastih opened 11 years ago

bastih commented 11 years ago

https://github.com/hyrise/hyrise/blob/master/src/lib/layouter/base.cpp#L1037

stop reaches .size() in this fragment of code.

bastih commented 11 years ago

is this a valid fix here?

size_t stop = index+1;
while (stop < subsets.size())
    if (subsets[stop++].size() > currentSize)
      break;
grundprinzip commented 11 years ago

How come this was never noticed before? I'm still not sure for the fix, well it should work, but I'm not sure if there is an edge case in the code...

bastih commented 11 years ago

I just ran the code with activated address sanitizer and this was one of the errors that came out of it.