When using the unsuitable callback, the unsuitable method is passed to C through a global variable. Therefore at least in this case, the code is not thread-safe. It should be thread-safe (not tested though) if -u is not used.
For making the code thread-safe, the unsuitable callback should be made part of TriangulateIO in the C library after checking if this is possible withot mayor modification of triangle.c .
Meanwhile the advise is to put a lock around triangulate calls in multithreaded code.
When using the unsuitable callback, the unsuitable method is passed to C through a global variable. Therefore at least in this case, the code is not thread-safe. It should be thread-safe (not tested though) if -u is not used.
For making the code thread-safe, the unsuitable callback should be made part of TriangulateIO in the C library after checking if this is possible withot mayor modification of triangle.c .
Meanwhile the advise is to put a lock around triangulate calls in multithreaded code.