mirror of
https://github.com/cirosantilli/linux-kernel-module-cheat.git
synced 2026-01-23 02:05:57 +01:00
pthread_self.c: mention gettid
This commit is contained in:
@@ -29,6 +29,10 @@
|
|||||||
* ....
|
* ....
|
||||||
*
|
*
|
||||||
* Note how the PID is the same for all threads.
|
* Note how the PID is the same for all threads.
|
||||||
|
*
|
||||||
|
* There is then a Linux specific gettid which returns a really unique thread ID:
|
||||||
|
* https://stackoverflow.com/questions/9305992/if-threads-share-the-same-pid-how-can-they-be-identified#comment42637433_9306150
|
||||||
|
* man gettid says that this value is different than pthread_self.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#define _XOPEN_SOURCE 700
|
#define _XOPEN_SOURCE 700
|
||||||
|
|||||||
Reference in New Issue
Block a user