mirror of
git://git.sv.gnu.org/emacs.git
synced 2025-12-15 10:30:25 -08:00
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.
This commit is contained in:
parent
7dcefa7a2b
commit
824f784187
5 changed files with 26 additions and 25 deletions
|
|
@ -120,6 +120,7 @@
|
|||
# mkostemp \
|
||||
# mktime \
|
||||
# nstrftime \
|
||||
# pathmax \
|
||||
# pipe2 \
|
||||
# pselect \
|
||||
# pthread_sigmask \
|
||||
|
|
@ -1076,6 +1077,7 @@ gl_GNULIB_ENABLED_getdtablesize = @gl_GNULIB_ENABLED_getdtablesize@
|
|||
gl_GNULIB_ENABLED_getgroups = @gl_GNULIB_ENABLED_getgroups@
|
||||
gl_GNULIB_ENABLED_malloca = @gl_GNULIB_ENABLED_malloca@
|
||||
gl_GNULIB_ENABLED_open = @gl_GNULIB_ENABLED_open@
|
||||
gl_GNULIB_ENABLED_pathmax = @gl_GNULIB_ENABLED_pathmax@
|
||||
gl_GNULIB_ENABLED_strtoll = @gl_GNULIB_ENABLED_strtoll@
|
||||
gl_LIBOBJS = @gl_LIBOBJS@
|
||||
gl_LTLIBOBJS = @gl_LTLIBOBJS@
|
||||
|
|
@ -2110,9 +2112,7 @@ endif
|
|||
## begin gnulib module pathmax
|
||||
ifeq (,$(OMIT_GNULIB_MODULE_pathmax))
|
||||
|
||||
ifneq (,$(gl_GNULIB_ENABLED_pathmax))
|
||||
|
||||
endif
|
||||
EXTRA_DIST += pathmax.h
|
||||
|
||||
endif
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue