summaryrefslogtreecommitdiff
path: root/lib/canonicalize-lgpl.c
diff options
context:
space:
mode:
authorPaul Eggert <eggert@cs.ucla.edu>2021-10-04 12:11:39 -0700
committerPaul Eggert <eggert@cs.ucla.edu>2021-10-04 15:21:31 -0700
commit68a256c89270ef9e97bca6097967a9ed2b050f4a (patch)
tree7a3cca947c133bf7def967083f1054dfa4239322 /lib/canonicalize-lgpl.c
parent63cb65dccecb1146cdad7134e4b62ea3e1433880 (diff)
downloademacs-68a256c89270ef9e97bca6097967a9ed2b050f4a.tar.gz
Update from Gnulib
Make the following changes by hand, and run 'admin/merge-gnulib'. * .gitignore: Add lib/malloc/*.gl.h. * admin/merge-gnulib: Copy lib/af_alg.h and lib/save-cwd.h directly from Gnulib, without worrying about Gnulib modules, as these files are special cases. (AVOIDED_MODULES): Remove malloc-posix. * lib/malloc.c, lib/realloc.c, m4/malloc.m4, m4/realloc.m4: * m4/year2038.m4: New files, copied from Gnulib. * lib/malloca.c, lib/malloca.h: * m4/close-stream.m4, m4/glibc21.m4, m4/malloca.m4: Remove. These are either no longer present in Gnulib, or are no longer needed by modules that Emacs uses. * oldXMenu/AddPane.c, oldXmenu/Addsel.c: Include XmenuInt.h first; needed for new Gnulib. * src/xmenu.c: Call emacs_abort, not abort.
Diffstat (limited to 'lib/canonicalize-lgpl.c')
-rw-r--r--lib/canonicalize-lgpl.c18
1 files changed, 11 insertions, 7 deletions
diff --git a/lib/canonicalize-lgpl.c b/lib/canonicalize-lgpl.c
index b7dba08994d..92e96397206 100644
--- a/lib/canonicalize-lgpl.c
+++ b/lib/canonicalize-lgpl.c
@@ -3,16 +3,16 @@
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
- modify it under the terms of the GNU General Public
+ modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
- version 3 of the License, or (at your option) any later version.
+ version 2.1 of the License, or (at your option) any later version.
The GNU C Library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- General Public License for more details.
+ Lesser General Public License for more details.
- You should have received a copy of the GNU General Public
+ You should have received a copy of the GNU Lesser General Public
License along with the GNU C Library; if not, see
<https://www.gnu.org/licenses/>. */
@@ -21,7 +21,6 @@
optimizes away the name == NULL test below. */
# define _GL_ARG_NONNULL(params)
-# define _GL_USE_STDLIB_ALLOC 1
# include <libc-config.h>
#endif
@@ -75,7 +74,12 @@
# define __pathconf pathconf
# define __rawmemchr rawmemchr
# define __readlink readlink
-# define __stat stat
+# if IN_RELOCWRAPPER
+ /* When building the relocatable program wrapper, use the system's memmove
+ function, not the gnulib override, otherwise we would get a link error.
+ */
+# undef memmove
+# endif
#endif
/* Suppress bogus GCC -Wmaybe-uninitialized warnings. */
@@ -100,7 +104,7 @@ file_accessible (char const *file)
return __faccessat (AT_FDCWD, file, F_OK, AT_EACCESS) == 0;
# else
struct stat st;
- return __stat (file, &st) == 0 || errno == EOVERFLOW;
+ return stat (file, &st) == 0 || errno == EOVERFLOW;
# endif
}