X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=src%2Fsrc%2Freadconf.c;h=27a834b3f7234cd21105b0f0a93e86a8f0f54a83;hb=e3555426308395ef260b0dae4548593ac114aed5;hp=a23a57ce86355a912c0e0e11b78fe15e003d4ba3;hpb=76ac1b5bce3ce3e3cc4c49c5c42b568f2a65ceee;p=user%2Fhenk%2Fcode%2Fexim.git diff --git a/src/src/readconf.c b/src/src/readconf.c index a23a57ce8..27a834b3f 100644 --- a/src/src/readconf.c +++ b/src/src/readconf.c @@ -445,6 +445,7 @@ static optionlist optionlist_config[] = { { "strip_trailing_dot", opt_bool, &strip_trailing_dot }, { "syslog_duplication", opt_bool, &syslog_duplication }, { "syslog_facility", opt_stringptr, &syslog_facility_str }, + { "syslog_pid", opt_bool, &syslog_pid }, { "syslog_processname", opt_stringptr, &syslog_processname }, { "syslog_timestamp", opt_bool, &syslog_timestamp }, { "system_filter", opt_stringptr, &system_filter }, @@ -567,6 +568,7 @@ macro_create(const uschar * name, const uschar * val, unsigned namelen = Ustrlen(name); macro_item * m = store_get(sizeof(macro_item) + namelen); +/* fprintf(stderr, "%s: '%s' '%s'\n", __FUNCTION__, name, val) */ if (!macros) { macros = m; @@ -762,6 +764,9 @@ due to conflicts with other common macros. */ #ifdef SUPPORT_SOCKS macro_create(US"_HAVE_SOCKS", US"y", FALSE, TRUE); #endif +#ifdef TCP_FASTOPEN + macro_create(US"_HAVE_TCP_FASTOPEN", US"y", FALSE, TRUE); +#endif #ifdef EXPERIMENTAL_LMDB macro_create(US"_HAVE_LMDB", US"y", FALSE, TRUE); #endif @@ -862,8 +867,14 @@ readconf_options_from_list(optionlist * opts, unsigned nopt, uschar * group) int i; const uschar * s; -/* Walk the array backwards to get substring-conflict names */ -for (i = nopt-1; i >= 0; i--) if (*(s = opts[i].name) && *s != '*') +/* The 'previously-defined-substring' rule for macros in config file +lines is done so for these builtin macros: we know that the table +we source from is in strict alpha order, hence the builtins portion +of the macros list is in reverse-alpha (we prepend them) - so longer +macros that have substrings are always discovered first during +expansion. */ + +for (i = 0; i < nopt; i++) if (*(s = opts[i].name) && *s != '*') macro_create(string_sprintf("_OPT_%T_%T", group, s), US"y", FALSE, TRUE); } @@ -1006,6 +1017,7 @@ for (;;) for (t = s; (p = CUstrchr(t, '_')); t = p+1) if (c = p[1], c == 'O' || c == 'D' || c == 'H') { +/* fprintf(stderr, "%s: builtins create triggered by '%s'\n", __FUNCTION__, s); */ macros_create_builtin(); break; } @@ -1025,6 +1037,7 @@ for (;;) int moveby; int replen = Ustrlen(m->replacement); +/* fprintf(stderr, "%s: matched '%s' in '%s'\n", __FUNCTION__, m->name, t) */ /* Expand the buffer if necessary */ while (newlen - m->namelen + replen + 1 > big_buffer_size)