Mercurial > hg > xemacs-beta
diff lib-src/movemail.c @ 442:abe6d1db359e r21-2-36
Import from CVS: tag r21-2-36
author | cvs |
---|---|
date | Mon, 13 Aug 2007 11:35:02 +0200 |
parents | 8de8e3f6228a |
children | 4a2749e56f92 |
line wrap: on
line diff
--- a/lib-src/movemail.c Mon Aug 13 11:33:40 2007 +0200 +++ b/lib-src/movemail.c Mon Aug 13 11:35:02 2007 +0200 @@ -69,7 +69,7 @@ #include <errno.h> #include "../src/sysfile.h" #include "../src/syswait.h" -#ifndef WINDOWSNT +#ifndef WIN32_NATIVE #include "../src/systime.h" #endif #include <stdlib.h> @@ -87,10 +87,6 @@ char * strerror (int errnum); #endif /* HAVE_STRERROR */ -#ifdef MSDOS -#undef access -#endif /* MSDOS */ - #ifndef DIRECTORY_SEP #define DIRECTORY_SEP '/' #endif @@ -98,7 +94,7 @@ #define IS_DIRECTORY_SEP(_c_) ((_c_) == DIRECTORY_SEP) #endif -#ifdef WINDOWSNT +#ifdef WIN32_NATIVE #undef access #undef unlink #define fork() 0 @@ -110,7 +106,7 @@ properly - make sure it does before you enable this! */ #define DISABLE_DIRECT_ACCESS #include <io.h> -#endif /* WINDOWSNT */ +#endif /* WIN32_NATIVE */ #if defined (HAVE_UNISTD_H) #include <unistd.h> @@ -204,7 +200,9 @@ #define DEFAULT_LOCKING DOTLOCKING #endif +#ifndef DISABLE_DIRECT_ACCESS static void lock_dot(char *); +#endif static void unlock_dot(char *); static int parse_lock_method(char *); static char *unparse_lock_method(int); @@ -341,7 +339,7 @@ exit (retcode); } -#ifndef WINDOWSNT +#ifndef WIN32_NATIVE setuid (getuid ()); #endif #endif /* MAIL_USE_POP */ @@ -566,6 +564,7 @@ static char *dotlock_filename = NULL; +#ifndef DISABLE_DIRECT_ACCESS static void lock_dot(char *filename) { @@ -625,6 +624,7 @@ } strcpy(dotlock_filename, filename); } +#endif /* not DISABLE_DIRECT_ACCESS */ static void unlock_dot(char *filename) @@ -705,7 +705,7 @@ #ifdef MAIL_USE_POP -#ifndef WINDOWSNT +#ifndef WIN32_NATIVE #include <sys/socket.h> #include <netinet/in.h> #include <netdb.h> @@ -714,7 +714,7 @@ #include <winsock.h> #endif #include <stdio.h> -#include <pwd.h> +#include "../src/syspwd.h" #define POP_ERROR (-1) #define POP_RETRIEVED (0) @@ -770,7 +770,7 @@ error ("Error in open: %s, %s", strerror (errno), outfile); return (1); } -#if !defined(__CYGWIN32__) && !defined(WINDOWSNT) +#if !defined(CYGWIN) && !defined(WIN32_NATIVE) fchown (mbfi, getuid (), (gid_t) -1); #endif