]> Savannah Git Hosting - gnulib.git/commit
getcwd: fix test failure on OS X 10.9
authorPádraig Brady <P@draigBrady.com>
Tue, 16 Dec 2014 02:35:19 +0000 (02:35 +0000)
committerPádraig Brady <P@draigBrady.com>
Tue, 16 Dec 2014 09:07:27 +0000 (09:07 +0000)
commit4f3dc0beed3e47ce1945dd5f8ff993e9971223c0
treef66b9d2884b3d65dd0ca236723fd72740465094f
parent1fafbb302d231d0a28a8445c8f18fcb397021556
getcwd: fix test failure on OS X 10.9

* m4/getcwd-path-max.m4: Avoid the replacement if it
won't be effective due to the PATH_MAX limitation of lstat().
(gl_cv_func_getcwd_path_max): Adjust to indicate this case.
* m4/getcwd.m4 (gl_FUNC_GETCWD): Define HAVE_GETCWD_SHORTER
for this case for use in tests, and also exclude this
case when setting REPLACE_GETCWD.
* tests/test-getcwd.c (test_long_name): Restrict the
tested path length so that lstat() will not be passed
a path greater than PATH_MAX.
Also key a test condition on HAVE_OPENAT_SUPPORT rather
than AT_FDCWD, since the latter is set unconditionally
since Sep 2009 in commit 52c658e9.
ChangeLog
m4/getcwd-path-max.m4
m4/getcwd.m4
tests/test-getcwd.c