digitalmars.D - PR: localtime vs. localtime_r
- FeepingCreature (8/8) Apr 03 2018 Hi, can somebody please review
Hi, can somebody please review https://github.com/dlang/phobos/pull/6366 ? Phobos currently calls localtime() to handle timezones, which breaks insidiously in multithreaded programs and occasionally silently returns wrong times. localtime_r() support is not 100% universal, but localtime() is universally wrong. (Except under Windows, where it does the right thing and returns a threadlocal pointer. Go figure.)
Apr 03 2018