Tweak AFSDIR_PATH_MAX definition
authorBenjamin Kaduk <kaduk@mit.edu>
Mon, 8 Sep 2014 17:47:33 +0000 (13:47 -0400)
committerD Brashear <shadow@your-file-system.com>
Wed, 8 Oct 2014 14:55:38 +0000 (10:55 -0400)
commitec2382e060753dfdcaf84b9ac03e1534c65fcdbc
tree572991d1f43a5e86ae70c3a1ecb922a0b5db9205
parent4514dbb1c4527a91a41e2a29c8a721091f6351a9
Tweak AFSDIR_PATH_MAX definition

On recent Debian, we run into runtime errors in the test suite
because _POSIX_PATH_MAX is only 256, and that buffer is too small
for a call to realpath().  Use PATH_MAX if it's available and larger
than _POSIX_PATH_MAX, in a way that should be safe even when PATH_MAX
is not defined.

Change-Id: I39127e88d92b358245ece21131219380ca4be98a
Reviewed-on: http://gerrit.openafs.org/11453
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
Reviewed-by: Chas Williams - CONTRACTOR <chas@cmf.nrl.navy.mil>
Reviewed-by: Perry Ruiter <pruiter@sinenomine.net>
Reviewed-by: D Brashear <shadow@your-file-system.com>
Tested-by: D Brashear <shadow@your-file-system.com>
src/util/dirpath.hin