V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
Distributions
Ubuntu
Fedora
CentOS
中文资源站
网易开源镜像站
josephok
V2EX  ›  Linux

errno 是如何实现线程安全的?

  •  
  •   josephok · 2015-01-05 12:28:43 +08:00 · 2727 次点击
    这是一个创建于 3415 天前的主题,其中的信息可能已经有所发展或是发生改变。
    3 条回复    2015-01-06 20:08:25 +08:00
    songco
        1
    songco  
       2015-01-05 12:39:08 +08:00
    linux下是thread-local的, posix某个版本开始好像也有类似的定义.
    flewover
        2
    flewover  
       2015-01-05 12:39:19 +08:00
    [Thread-safety and POSIX.1](http://www.unix.org/whitepapers/reentrant.html)

    Redefinition of errno 那部分
    c4pt0r
        3
    c4pt0r  
       2015-01-06 20:08:25 +08:00
    thread local
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   实用小工具   ·   6058 人在线   最高记录 6547   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 41ms · UTC 03:26 · PVG 11:26 · LAX 20:26 · JFK 23:26
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.