[dovecot-cvs] dovecot/src/master ssl-init.c,1.15,1.16

cras at dovecot.org cras at dovecot.org
Sun Jan 15 17:22:51 EET 2006


Update of /var/lib/cvs/dovecot/src/master
In directory talvi:/tmp/cvs-serv24041

Modified Files:
	ssl-init.c 
Log Message:
If SSL parameters file is empty, unlink it



Index: ssl-init.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/master/ssl-init.c,v
retrieving revision 1.15
retrieving revision 1.16
diff -u -d -r1.15 -r1.16
--- ssl-init.c	15 Jan 2006 12:35:04 -0000	1.15
+++ ssl-init.c	15 Jan 2006 15:22:49 -0000	1.16
@@ -86,6 +86,11 @@
 		st.st_mtime = 0;
 	}
 
+	if (st.st_size == 0) {
+		/* broken, delete it (mostly for backwards compatibility) */
+		(void)unlink(set->ssl_parameters_file);
+	}
+
 	/* make sure it's new enough, it's not 0 sized, and the permissions
 	   are correct */
 	regen_time = st.st_mtime +



More information about the dovecot-cvs mailing list