ignore the comment in limits.h and define NAME_MAX
There's a bunch of standards handwaving and lunacy in limits.h about why we don't define NAME_MAX.
We should ignore it, delete the comment, and define it for the sake of compatibility (presumably to the same value as MAXNAMELEN).
As best as I can tell, the hand-wringing in the header is for the sake of pcfs and s5fs!
Updated by Igor Pashev over 10 years ago
Yes, finally :-)
Updated by Gary Mills almost 8 years ago
Surely it would be (MAXNAMELEN-1) which would be 255. NAME_MAX is not supposed to include a terminating NUL.
Updated by Alain O'Dea over 7 years ago
I got bitten by this trying to build and install fswatch. I had to create a trivial patch to define NAME_MAX to get past it.
Updated by Andrew Stormont about 6 years ago
How's this? http://cr.illumos.org/~webrev/andy_js/3188
Updated by Electric Monk about 6 years ago
- Status changed from New to Closed
- % Done changed from 0 to 100
git commit 9c0752ac0dc05794d2f8a8b4521d55e2b3f63247
commit 9c0752ac0dc05794d2f8a8b4521d55e2b3f63247 Author: Andrew Stormont <firstname.lastname@example.org> Date: 2017-04-27T00:22:44.000Z 3188 ignore the comment in limits.h and define NAME_MAX Reviewed by: Jason King <email@example.com> Reviewed by: Peter Tribble <firstname.lastname@example.org> Reviewed by: Sam Zaydel <email@example.com> Approved by: Robert Mustacchi <firstname.lastname@example.org>