summary refs log tree commit diff
path: root/locale
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2013-05-25 14:38:38 -0400
committerMike Frysinger <vapier@gentoo.org>2013-05-25 14:38:38 -0400
commit0e60d68ef0f755bfd2319937774b8a08f79ca7f1 (patch)
treeea8f546e432762a53bbe4fb76d4567d7da529410 /locale
parent56b672e92e10ac2931236dba4e452699fd0d32d1 (diff)
downloadglibc-0e60d68ef0f755bfd2319937774b8a08f79ca7f1.tar.gz
glibc-0e60d68ef0f755bfd2319937774b8a08f79ca7f1.tar.xz
glibc-0e60d68ef0f755bfd2319937774b8a08f79ca7f1.zip
localedef: include file name in error messages
When mkstemp fails, the error message the user gets back is:
cannot create temporary file: No such file or directory

That isn't terribly useful in figuring out why, so include the full
filename we tried to create in the error output.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Diffstat (limited to 'locale')
-rw-r--r--locale/programs/locarchive.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/locale/programs/locarchive.c b/locale/programs/locarchive.c
index d31472d908..2f544893b6 100644
--- a/locale/programs/locarchive.c
+++ b/locale/programs/locarchive.c
@@ -111,7 +111,7 @@ create_archive (const char *archivefname, struct locarhandle *ah)
   /* Create a temporary file in the correct directory.  */
   fd = mkstemp (fname);
   if (fd == -1)
-    error (EXIT_FAILURE, errno, _("cannot create temporary file"));
+    error (EXIT_FAILURE, errno, _("cannot create temporary file: %s"), fname);
 
   /* Create the initial content of the archive.  */
   head.magic = AR_MAGIC;
@@ -345,7 +345,7 @@ enlarge_archive (struct locarhandle *ah, const struct locarhead *head)
   /* Create a temporary file in the correct directory.  */
   fd = mkstemp (fname);
   if (fd == -1)
-    error (EXIT_FAILURE, errno, _("cannot create temporary file"));
+    error (EXIT_FAILURE, errno, _("cannot create temporary file: %s"), fname);
 
   /* Copy the existing head information.  */
   newhead = *head;