From e94526c53d4b81b4040ba60a0341684697af17e4 Mon Sep 17 00:00:00 2001 From: "Heiko Schlittermann (HS12-RIPE)" Date: Tue, 27 Dec 2016 23:07:55 +0100 Subject: [PATCH] Testsuite: fix 0903 --- src/src/readconf.c | 1 + test/confs/0903 | 2 +- test/scripts/0000-Basic/0903 | 2 +- test/stdout/0903 | 7 +++++++ 4 files changed, 10 insertions(+), 2 deletions(-) create mode 100644 test/stdout/0903 diff --git a/src/src/readconf.c b/src/src/readconf.c index 46dc7ced2..21328bd3a 100644 --- a/src/src/readconf.c +++ b/src/src/readconf.c @@ -1178,6 +1178,7 @@ for (;;) int offset = 0; int size = 0; ss = string_append(NULL, &size, &offset, 3, config_directory, "/", ss); + ss[offset] = '\0'; /* string_append() does not zero terminate the string! */ } if (include_if_exists != 0 && (Ustat(ss, &statbuf) != 0)) continue; diff --git a/test/confs/0903 b/test/confs/0903 index 6005468c2..017424e24 100644 --- a/test/confs/0903 +++ b/test/confs/0903 @@ -1 +1 @@ -.include 0903./aaa +.include confs/0903./aaa diff --git a/test/scripts/0000-Basic/0903 b/test/scripts/0000-Basic/0903 index a29e94949..1bd510ae3 100644 --- a/test/scripts/0000-Basic/0903 +++ b/test/scripts/0000-Basic/0903 @@ -1,2 +1,2 @@ # Test different variants of .includes -exim +exim -bP config diff --git a/test/stdout/0903 b/test/stdout/0903 new file mode 100644 index 000000000..a7bda45dc --- /dev/null +++ b/test/stdout/0903 @@ -0,0 +1,7 @@ +# Exim Configuration (X) +# 1 "TESTSUITE/test-config" +# 1 "TESTSUITE/test-config" +# 1 "TESTSUITE/confs/0903./aaa" +# 1 "TESTSUITE/confs/0903./aaa" +# 1 "TESTSUITE/confs/0903./aaa" +# 1 "TESTSUITE/test-config" -- 2.25.1