[dovecot-cvs] dovecot/src/dict main.c,1.8.2.1,1.8.2.2
cras at dovecot.org
cras at dovecot.org
Thu Aug 10 21:46:22 EEST 2006
Update of /var/lib/cvs/dovecot/src/dict
In directory talvi:/tmp/cvs-serv17051/dict
Modified Files:
Tag: branch_1_0
main.c
Log Message:
Require that master's version number matches the child's, unless
version_ignore=yes. Usually it's an accidental installation problem if the
version numbers don't match.
Index: main.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/dict/main.c,v
retrieving revision 1.8.2.1
retrieving revision 1.8.2.2
diff -u -d -r1.8.2.1 -r1.8.2.2
--- main.c 17 Jun 2006 11:24:09 -0000 1.8.2.1
+++ main.c 10 Aug 2006 18:46:19 -0000 1.8.2.2
@@ -56,9 +56,16 @@
static void main_init(void)
{
- const char *path;
+ const char *value, *path;
int fd;
+ value = getenv("DOVECOT_VERSION");
+ if (value != NULL && strcmp(value, PACKAGE_VERSION) != 0) {
+ i_fatal("Dovecot version mismatch: "
+ "Master is v%s, dict is v"PACKAGE_VERSION" "
+ "(if you don't care, set version_ignore=yes)", value);
+ }
+
lib_signals_init();
lib_signals_set_handler(SIGINT, TRUE, sig_die, NULL);
lib_signals_set_handler(SIGTERM, TRUE, sig_die, NULL);
More information about the dovecot-cvs
mailing list