[dovecot-cvs] dovecot/src/auth userinfo-pam.c,1.5,1.6 userinfo-passwd-file.c,1.9,1.10 userinfo-passwd.c,1.4,1.5 userinfo-passwd.h,1.1.1.1,1.2 userinfo-shadow.c,1.4,1.5 userinfo-vpopmail.c,1.1,1.2

cras at procontrol.fi cras at procontrol.fi
Mon Nov 4 07:04:06 EET 2002


Update of /home/cvs/dovecot/src/auth
In directory danu:/tmp/cvs-serv28329

Modified Files:
	userinfo-pam.c userinfo-passwd-file.c userinfo-passwd.c 
	userinfo-passwd.h userinfo-shadow.c userinfo-vpopmail.c 
Log Message:
Fixed warnings when compiling with Solaris 8



Index: userinfo-pam.c
===================================================================
RCS file: /home/cvs/dovecot/src/auth/userinfo-pam.c,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -d -r1.5 -r1.6
--- userinfo-pam.c	3 Nov 2002 00:09:33 -0000	1.5
+++ userinfo-pam.c	4 Nov 2002 05:04:04 -0000	1.6
@@ -7,23 +7,14 @@
    modified versions are marked as such.  There's absolutely no warranty.
 */
 
-#ifndef _XOPEN_SOURCE_EXTENDED
-#  define _XOPEN_SOURCE_EXTENDED
-#endif
-#define _XOPEN_SOURCE 4
-#define _XPG4_2
-
-#include "common.h"
+#include "config.h"
+#undef HAVE_CONFIG_H
 
 #ifdef USERINFO_PAM
 
-#include "userinfo.h"
 #include "userinfo-passwd.h"
 
 #include <stdlib.h>
-#include <unistd.h>
-#include <shadow.h>
-
 #include <security/pam_appl.h>
 
 #if !defined(_SECURITY_PAM_APPL_H) && !defined(LINUX_PAM)

Index: userinfo-passwd-file.c
===================================================================
RCS file: /home/cvs/dovecot/src/auth/userinfo-passwd-file.c,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -d -r1.9 -r1.10
--- userinfo-passwd-file.c	28 Oct 2002 09:46:02 -0000	1.9
+++ userinfo-passwd-file.c	4 Nov 2002 05:04:04 -0000	1.10
@@ -1,24 +1,18 @@
 /* Copyright (C) 2002 Timo Sirainen */
 
-#ifndef _XOPEN_SOURCE_EXTENDED
-#  define _XOPEN_SOURCE_EXTENDED
-#endif
-#define _XOPEN_SOURCE 4
-#define _XPG4_2
-
-#include "common.h"
+#include "config.h"
+#undef HAVE_CONFIG_H
 
 #ifdef USERINFO_PASSWD_FILE
 
+#include "userinfo-passwd.h"
+
 #include "ibuffer.h"
 #include "hash.h"
 #include "hex-binary.h"
 #include "md5.h"
-#include "userinfo.h"
-#include "userinfo-passwd.h"
 
 #include <stdlib.h>
-#include <unistd.h>
 #include <fcntl.h>
 #include <sys/stat.h>
 

Index: userinfo-passwd.c
===================================================================
RCS file: /home/cvs/dovecot/src/auth/userinfo-passwd.c,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -d -r1.4 -r1.5
--- userinfo-passwd.c	5 Oct 2002 21:13:22 -0000	1.4
+++ userinfo-passwd.c	4 Nov 2002 05:04:04 -0000	1.5
@@ -5,20 +5,12 @@
    Copyright (C) 2002 Timo Sirainen
 */
 
-#ifndef _XOPEN_SOURCE_EXTENDED
-#  define _XOPEN_SOURCE_EXTENDED
-#endif
-#define _XOPEN_SOURCE 4
-#define _XPG4_2
-
-#include "common.h"
+#include "config.h"
+#undef HAVE_CONFIG_H
 
 #ifdef USERINFO_PASSWD
 
-#include "userinfo.h"
 #include "userinfo-passwd.h"
-
-#include <unistd.h>
 
 void passwd_fill_cookie_reply(struct passwd *pw, AuthCookieReplyData *reply)
 {

Index: userinfo-passwd.h
===================================================================
RCS file: /home/cvs/dovecot/src/auth/userinfo-passwd.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -u -d -r1.1.1.1 -r1.2
--- userinfo-passwd.h	9 Aug 2002 09:16:16 -0000	1.1.1.1
+++ userinfo-passwd.h	4 Nov 2002 05:04:04 -0000	1.2
@@ -1,6 +1,21 @@
 #ifndef __USERINFO_PASSWD_H
 #define __USERINFO_PASSWD_H
 
+/* can't remember what these were for. needed in some systems I think :) */
+#ifndef _XOPEN_SOURCE_EXTENDED
+#  define _XOPEN_SOURCE_EXTENDED
+#endif
+#define _XPG4_2
+
+/* _XOPEN_SOURCE is required for crypt(). However with Solaris 8 it breaks
+   a few other header files so keep it defined only for unistd.h */
+#define _XOPEN_SOURCE 4 /* needed for crypt() */
+#include <unistd.h>
+#undef _XOPEN_SOURCE
+
+#include "common.h"
+#include "userinfo.h"
+
 #include <pwd.h>
 
 #define IS_VALID_PASSWD(pass) \

Index: userinfo-shadow.c
===================================================================
RCS file: /home/cvs/dovecot/src/auth/userinfo-shadow.c,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -d -r1.4 -r1.5
--- userinfo-shadow.c	5 Oct 2002 21:13:22 -0000	1.4
+++ userinfo-shadow.c	4 Nov 2002 05:04:04 -0000	1.5
@@ -5,20 +5,13 @@
    Copyright (C) 2002 Timo Sirainen
 */
 
-#ifndef _XOPEN_SOURCE_EXTENDED
-#  define _XOPEN_SOURCE_EXTENDED
-#endif
-#define _XOPEN_SOURCE 4
-#define _XPG4_2
-
-#include "common.h"
+#include "config.h"
+#undef HAVE_CONFIG_H
 
 #ifdef USERINFO_SHADOW
 
-#include "userinfo.h"
 #include "userinfo-passwd.h"
 
-#include <unistd.h>
 #include <shadow.h>
 
 static int shadow_verify_plain(const char *user, const char *password,

Index: userinfo-vpopmail.c
===================================================================
RCS file: /home/cvs/dovecot/src/auth/userinfo-vpopmail.c,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- userinfo-vpopmail.c	20 Sep 2002 11:27:18 -0000	1.1
+++ userinfo-vpopmail.c	4 Nov 2002 05:04:04 -0000	1.2
@@ -2,14 +2,13 @@
 
 /* Thanks to Courier-IMAP for showing how the vpopmail API should be used */
 
-#include "common.h"
+#include "config.h"
+#undef HAVE_CONFIG_H
 
 #ifdef USERINFO_VPOPMAIL
 
-#include "userinfo.h"
 #include "userinfo-passwd.h"
 
-#include <unistd.h>
 #include <vpopmail.h>
 #include <vauth.h>
 




More information about the dovecot-cvs mailing list