aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEli Zaretskii2000-09-01 13:50:50 +0000
committerEli Zaretskii2000-09-01 13:50:50 +0000
commitf72adc12d5669d5cc64ff6539dc36e74afefb79d (patch)
treef280aa91baf5f2ee89118e3092e30992e5dcfb93
parent38404229887345de92c7ab0da85a5d0f7aaaf585 (diff)
downloademacs-f72adc12d5669d5cc64ff6539dc36e74afefb79d.tar.gz
emacs-f72adc12d5669d5cc64ff6539dc36e74afefb79d.zip
(toplevel): Remove redundant <fcntl.h>. Provide definitions for F_OK
and friends only after including both fcntl.h and unistd.h: some systems define them on unistd.h.
-rw-r--r--lib-src/ChangeLog6
-rw-r--r--lib-src/movemail.c12
2 files changed, 10 insertions, 8 deletions
diff --git a/lib-src/ChangeLog b/lib-src/ChangeLog
index 4baa7cd7ff4..890d3a77370 100644
--- a/lib-src/ChangeLog
+++ b/lib-src/ChangeLog
@@ -1,3 +1,9 @@
12000-09-01 Eli Zaretskii <eliz@is.elta.co.il>
2
3 * movemail.c (toplevel): Remove redundant fcnt.h.
4 [!F_OK]: Provide default definitions only after including both
5 fcntl.h and unistd.h.
6
12000-08-29 Eli Zaretskii <eliz@is.elta.co.il> 72000-08-29 Eli Zaretskii <eliz@is.elta.co.il>
2 8
3 * Makefile.in (profile, make-docfile, hexl): Depend on config.h. 9 * Makefile.in (profile, make-docfile, hexl): Depend on config.h.
diff --git a/lib-src/movemail.c b/lib-src/movemail.c
index d37644063e1..cfe817c1119 100644
--- a/lib-src/movemail.c
+++ b/lib-src/movemail.c
@@ -62,11 +62,14 @@ Boston, MA 02111-1307, USA. */
62#include <stdio.h> 62#include <stdio.h>
63#include <errno.h> 63#include <errno.h>
64 64
65#include "syswait.h"
66#include <getopt.h> 65#include <getopt.h>
66#ifdef HAVE_UNISTD_H
67#include <unistd.h>
68#endif
67#ifdef HAVE_FCNTL_H 69#ifdef HAVE_FCNTL_H
68#include <fcntl.h> 70#include <fcntl.h>
69#endif 71#endif
72#include "syswait.h"
70#ifdef MAIL_USE_POP 73#ifdef MAIL_USE_POP
71#include "pop.h" 74#include "pop.h"
72#endif 75#endif
@@ -102,9 +105,6 @@ Boston, MA 02111-1307, USA. */
102#include <fcntl.h> 105#include <fcntl.h>
103#endif /* WINDOWSNT */ 106#endif /* WINDOWSNT */
104 107
105#ifdef HAVE_FCNTL_H
106#include <fcntl.h>
107#endif
108#ifndef F_OK 108#ifndef F_OK
109#define F_OK 0 109#define F_OK 0
110#define X_OK 1 110#define X_OK 1
@@ -112,10 +112,6 @@ Boston, MA 02111-1307, USA. */
112#define R_OK 4 112#define R_OK 4
113#endif 113#endif
114 114
115#ifdef HAVE_UNISTD_H
116#include <unistd.h>
117#endif
118
119#if defined (XENIX) || defined (WINDOWSNT) 115#if defined (XENIX) || defined (WINDOWSNT)
120#include <sys/locking.h> 116#include <sys/locking.h>
121#endif 117#endif