It's a long time... Since the last post . But I would like to post the Two definitions
According to the C++ Gui programming Book
Thread-safe : A function is said to be thread-safe when it can safely be called from different threads simultaneously. If two thread-safe functions are called from different threads on the same shared data, the result is always defined. By extension, a class is said to be thread-safe when all of its functions can be called from different threads simultaneously without interfering with each other, even when operating on the same object.
Reentrant : A class is reentrant if different instances of the class can be used simultaneously in different threads. However, accessing the same reentrant object in multiple threads simultaneously is not safe,and such accesses should be protected with a mutex. Reentrant classes are marked as such in the Qt reference documentation. Typically, any C++ class that doesn t reference global or otherwise shared data is reentrant. QObject is reentrant, but none of Qt s (3.x) QObject subclasses are reentrant.
Bookmarks