How is pthread_mutex_t used for a multi source C project.
Is there a global pthread_mutex_t in a header file or does each source file defines it's own?
How many times pthread_mutex_init is used? only once per mutex?
So if we use a global mutex, we only need to use pthread_mutex_init once in the beginning of main?