X-Git-Url: https://git.exim.org/exim.git/blobdiff_plain/b3c261f710276f28ea23bf86dddacdf5fb4612b4..084c1d8c14da86888bbffc31a54246dc6e2e8147:/src/src/exim.c diff --git a/src/src/exim.c b/src/src/exim.c index 3592f30dd..528ffc7c8 100644 --- a/src/src/exim.c +++ b/src/src/exim.c @@ -912,14 +912,6 @@ if (fixed_never_users[0] > 0) fprintf(f, "Size of off_t: " SIZE_T_FMT "\n", sizeof(off_t)); -/* This runtime check is to help diagnose library linkage mismatches which -result in segfaults and the like; as such, it's left until the end, -just in case. There will still be a "Configuration file is" line still to -come. */ -#ifdef SUPPORT_TLS -tls_version_report(f); -#endif - /* Everything else is details which are only worth reporting when debugging. Perhaps the tls_version_report should move into this too. */ DEBUG(D_any) do { @@ -941,6 +933,10 @@ DEBUG(D_any) do { fprintf(f, "Compiler: \n"); #endif +#ifdef SUPPORT_TLS + tls_version_report(f); +#endif + #ifdef AUTH_CYRUS_SASL auth_cyrus_sasl_version_report(f); #endif @@ -1418,7 +1414,19 @@ if (route_finduser(US EXIM_USERNAME, &pw, &exim_uid)) EXIM_USERNAME); exit(EXIT_FAILURE); } - exim_gid = pw->pw_gid; + /* If ref:name uses a number as the name, route_finduser() returns + TRUE with exim_uid set and pw coerced to NULL. */ + if (pw) + exim_gid = pw->pw_gid; +#ifndef EXIM_GROUPNAME + else + { + fprintf(stderr, + "exim: ref:name should specify a usercode, not a group.\n" + "exim: can't let you get away with it unless you also specify a group.\n"); + exit(EXIT_FAILURE); + } +#endif } else {