summaryrefslogtreecommitdiff
path: root/locale/programs/locarchive.c
diff options
context:
space:
mode:
authorSamuel Thibault <samuel.thibault@ens-lyon.org>2018-12-27 19:31:37 +0000
committerSamuel Thibault <samuel.thibault@ens-lyon.org>2018-12-27 19:31:37 +0000
commit74a412373b66a38b6ce8156f027ce26f89a7462f (patch)
treea59ce0af7ffd48641ca9124d697f7a6b57b26931 /locale/programs/locarchive.c
parent2004eeba8fb2a92105bbf95b280fff6dc1d84144 (diff)
parent4cbfda396f7cd9e83116c28965ade73d80c1cb82 (diff)
Merge commit 'refs/top-bases/t/ONSTACK' into t/ONSTACK
Diffstat (limited to 'locale/programs/locarchive.c')
-rw-r--r--locale/programs/locarchive.c12
1 files changed, 4 insertions, 8 deletions
diff --git a/locale/programs/locarchive.c b/locale/programs/locarchive.c
index fadc3bfd43..ca332a345f 100644
--- a/locale/programs/locarchive.c
+++ b/locale/programs/locarchive.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 2002-2016 Free Software Foundation, Inc.
+/* Copyright (C) 2002-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@redhat.com>, 2002.
@@ -40,8 +40,8 @@
#include <sys/shm.h>
#include <sys/stat.h>
-#include <libc-internal.h>
#include <libc-mmap.h>
+#include <libc-pointer-arith.h>
#include "../../crypt/md5.h"
#include "../localeinfo.h"
#include "../locarchive.h"
@@ -320,8 +320,8 @@ compare_from_file (struct locarhandle *ah, void *p1, uint32_t offset2,
{
void *p2 = xmalloc (size);
if (pread (ah->fd, p2, size, offset2) != size)
- WITH_CUR_LOCALE (error (4, errno,
- _("cannot read data from locale archive")));
+ record_error (4, errno,
+ _("cannot read data from locale archive"));
int res = memcmp (p1, p2, size);
free (p2);
@@ -1385,17 +1385,13 @@ add_locales_to_archive (size_t nlist, char *list[], bool replace)
a directory we have to look at a file with the
prefix "SYS_". Otherwise we have found what we
are looking for. */
-#ifdef _DIRENT_HAVE_D_TYPE
d_type = d->d_type;
if (d_type != DT_REG)
-#endif
{
char fullname[fnamelen + 2 * strlen (d->d_name) + 7];
-#ifdef _DIRENT_HAVE_D_TYPE
if (d_type == DT_UNKNOWN)
-#endif
{
strcpy (stpcpy (stpcpy (fullname, fname), "/"),
d->d_name);