Why do we write -D_REENTRANT while compiling C code using threads

Viewed 11862

We write this statement when we are compiling a C program that has threads implemented in them. I could not understand why we use -D_REENTRANT here. e.g gcc t1.c -lpthread -D_REENTRANT

3 Answers
Related