]> git.eshelyaron.com Git - emacs.git/commit
Prefer PATH_MAX to MAXPATHLEN
authorPaul Eggert <eggert@cs.ucla.edu>
Tue, 25 Jun 2019 22:54:37 +0000 (15:54 -0700)
committerPaul Eggert <eggert@cs.ucla.edu>
Tue, 25 Jun 2019 22:56:58 +0000 (15:56 -0700)
commit824f78418783ee0af1c804b0decb037a13a4365e
tree7a4127256fa1117b609b1d5c50c8490b391708e1
parent7dcefa7a2bb4d2531d23cbf51eb98ce7727b366c
Prefer PATH_MAX to MAXPATHLEN

PATH_MAX is standardized, MAXPATHLEN is not.
Also, the Gnulib pathmax module fixes some rare bugs with PATH_MAX.
So prefer PATH_MAX to MAXPATHLEN unless we know the latter is
also correct (for some platform-specific code).
* admin/merge-gnulib (GNULIB_MODULES): Add pathmax.
This module was already present, as a dependency of canonicalize-lgpl,
but now Emacs is using it directly.  Sort.
* lib-src/emacsclient.c: Include stdint.h, pathmax.h.
(get_current_dir_name): Sync to current src/sysdep.c.
* lib/gnulib.mk.in, m4/gnulib-comp.m4: Regenerate.
* src/sysdep.c: Include pathmax.h.
(get_current_dir_name_or_unreachable):
Use PATH_MAX instead of MAXPATHLEN.
admin/merge-gnulib
lib-src/emacsclient.c
lib/gnulib.mk.in
m4/gnulib-comp.m4
src/sysdep.c