aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/env_universal_common.cpp
Commit message (Collapse)AuthorAge
* Mark a bunch of constructors as explicitGravatar ridiculousfish2016-02-27
| | | | This prevents undesired implicit conversions
* Miscellaneous cleanup and dead code removalGravatar ridiculousfish2016-02-19
| | | | Noticed by cppcheck
* Check that $XDG_RUNTIME_DIR is valid and accessibleGravatar Tanner Bruce2015-12-11
| | | | Signed-off-by: David Adam <zanchey@ucc.gu.uwa.edu.au>
* env_universal_common.cpp: don't bother trying nonexistent pathGravatar David Adam2015-11-28
|
* Attempt to fix the sporadic uvar test failures on LinuxGravatar ridiculousfish2015-11-08
| | | | | | | | | | | | | | | | | | We identify when the universal variable file has changed out from under us by comparing a bunch of fields from its stat: inode, device, size, high-precision timestamp, generation. Linux aggressively reuses inodes, and the size may be the same by coincidence (which is the case in the tests). Also, Linux officially has nanosecond precision, but in practice it seems to only uses millisecond precision for storing mtimes. Thus if there are three or more updates within a millisecond, every field we check may be the same, and we are vulnerable to the ABA problem. I believe this explains the occasional test failures. The solution is to manually set the nanosecond field of the mtime timestamp to something unlikely to be duplicated, like a random number, or better yet, the current time (with nanosecond precision). This is more in the spirit of the timestamp, and it means we're around a million times less likely to collide. This seems to fix the tests.
* Maintain ownership when rewriting universal variables fileGravatar ridiculousfish2015-09-26
| | | | Fixes #2176
* env_universal_common: always pick shmem strategy on CygwinGravatar David Adam2015-08-24
| | | | | | | | Cygwin FIFOs do not support more than one reader, so avoid them on this platform. An autoconf feature test would be helpful but is tricky to write. Closes #2152.
* Merge branch 'master' into iwyuGravatar David Adam2015-07-26
|
* Migrate source files into src/ directoryGravatar ridiculousfish2015-07-24
This change moves source files into a src/ directory, and puts object files into an obj/ directory. The Makefile and xcode project are updated accordingly. Fixes #1866