I would like to use C++ 11 thread_local, but our application embeds a JVM, and sometimes C++ methods are called from Java-created thread via JNI. This could be the same thing as if an external "C" library created a thread and called back into my C++ code. Is the behavior of thread_local variables defined under these circumstances? Is there any way for my code to compensate for the unexpected appearance of a foreign thread? What about destruction on thread exit? Thanks john
Aucun commentaire:
Enregistrer un commentaire