diff options
author | Paul Eggert <eggert@cs.ucla.edu> | 2015-05-31 23:52:09 -0700 |
---|---|---|
committer | Paul Eggert <eggert@cs.ucla.edu> | 2015-05-31 23:53:45 -0700 |
commit | 2c656f7deb3b192a5063151368782c2715e81051 (patch) | |
tree | 94f93fae541ca21c126c53162242ae8403b8c9f3 /src/unexmacosx.c | |
parent | 467af178f53798e4cd102e04eb2990121eb655df (diff) | |
download | emacs-2c656f7deb3b192a5063151368782c2715e81051.tar.gz |
Avoid grave accent quoting in stderr diagnostics
A few Emacs diagnostics go directly to stderr, and so can't easily
contain curved quotes (as non-UTF-8 locales might mishandle them).
Instead of bothering to add support for this rarity, reword the
diagnostics so that they don't use grave accent to quote.
* src/alloc.c (mark_memory): Fix comment.
* src/buffer.c (init_buffer):
* src/dispnew.c (init_display):
* src/emacs.c (main, sort_args):
* src/lread.c (dir_warning):
* src/term.c (init_tty):
* src/unexmacosx.c (unexec):
* src/xfns.c (select_visual):
* src/xterm.c (cvt_string_to_pixel, x_io_error_quitter):
Reword stderr diagnostics to avoid quoting `like this'.
* src/unexmacosx.c: Include errno.h.
* src/xfns.c (select_visual): Encode value for locale.
Diffstat (limited to 'src/unexmacosx.c')
-rw-r--r-- | src/unexmacosx.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/unexmacosx.c b/src/unexmacosx.c index fe6637e2ef5..319ec7956e5 100644 --- a/src/unexmacosx.c +++ b/src/unexmacosx.c @@ -99,6 +99,7 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */ #include "unexec.h" #include "lisp.h" +#include <errno.h> #include <stdio.h> #include <fcntl.h> #include <stdarg.h> @@ -1264,14 +1265,14 @@ unexec (const char *outfile, const char *infile) infd = emacs_open (infile, O_RDONLY, 0); if (infd < 0) { - unexec_error ("cannot open input file `%s'", infile); + unexec_error ("%s: %s", infile, strerror (errno)); } outfd = emacs_open (outfile, O_WRONLY | O_TRUNC | O_CREAT, 0777); if (outfd < 0) { emacs_close (infd); - unexec_error ("cannot open output file `%s'", outfile); + unexec_error ("%s: %s", outfile, strerror (errno)); } build_region_list (); |