GraphViz.jl icon indicating copy to clipboard operation
GraphViz.jl copied to clipboard

Possible thread safety issue with `active_devices`

Open frankier opened this issue 4 years ago • 1 comments

The use of active_devices might not be thread safe if this library is used in more than one thread. Putting a new key in active_devices could cause it to be reallocated in one thread while another thread is reading which might cause undefined behaviour.

frankier avatar Feb 11 '22 09:02 frankier

Yes, Julia didn't have threading when this package was written. We'll need to add some locks. That said, I'm not sure that the graphviz library itself is thread safe, so we'll want to investigate that first.

Keno avatar Feb 11 '22 09:02 Keno