Skip to content

Fixed vtkExtractCells data race, simultaneous writes to same memory

Found by TSan.

Here the innermost loop will sometimes have multiple threads writing to the same part of the buffer simultaneously. This is undefined behaviour.

The solution is to use std::atomic, but the only way I can see how is to use a distasteful reinterpret_cast.

Merge request reports