aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorRichard M. Stallman1997-08-27 20:01:05 +0000
committerRichard M. Stallman1997-08-27 20:01:05 +0000
commit9dde47f5798a73946d3f78da2e0daff23457ea31 (patch)
tree44fea1fb881d071b51cb5156d52109e63e99ae6f /src
parent759ae8118b7267b4c4d82ec90721b73ee5bc263b (diff)
downloademacs-9dde47f5798a73946d3f78da2e0daff23457ea31.tar.gz
emacs-9dde47f5798a73946d3f78da2e0daff23457ea31.zip
Include errno.h.
(init_buffer) [HAVE_GETCWD]: Fix error message for getcwd failure.
Diffstat (limited to 'src')
-rw-r--r--src/buffer.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/buffer.c b/src/buffer.c
index 2b4c18fa189..47b4f150363 100644
--- a/src/buffer.c
+++ b/src/buffer.c
@@ -23,6 +23,9 @@ Boston, MA 02111-1307, USA. */
23#include <sys/types.h> 23#include <sys/types.h>
24#include <sys/stat.h> 24#include <sys/stat.h>
25#include <sys/param.h> 25#include <sys/param.h>
26#include <errno.h>
27
28extern int errno;
26 29
27#ifndef MAXPATHLEN 30#ifndef MAXPATHLEN
28/* in 4.1, param.h fails to define this. */ 31/* in 4.1, param.h fails to define this. */
@@ -3708,7 +3711,7 @@ init_buffer ()
3708 strcpy (buf, pwd); 3711 strcpy (buf, pwd);
3709#ifdef HAVE_GETCWD 3712#ifdef HAVE_GETCWD
3710 else if (getcwd (buf, MAXPATHLEN+1) == 0) 3713 else if (getcwd (buf, MAXPATHLEN+1) == 0)
3711 fatal ("`getcwd' failed: %s\n", buf); 3714 fatal ("`getcwd' failed: %s\n", strerror (errno));
3712#else 3715#else
3713 else if (getwd (buf) == 0) 3716 else if (getwd (buf) == 0)
3714 fatal ("`getwd' failed: %s\n", buf); 3717 fatal ("`getwd' failed: %s\n", buf);