Unix编程[一] errno线程安全

1761阅读 0评论2010-01-11 iedey
分类:LINUX

     Linux,errno默认是线程安全的,在头文件中的定义:

/* Function to get address of global 'errno' variable. */

extern int *__errno_location (void) __THROW __attribute__ ((__const__));



/* When using threads, errno is a per-thread value. */

# define errno (*__errno_location ())


上一篇:可重入和不可重入
下一篇:Unix编程[二] read