summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeremy Harris <jgh146exb@wizmail.org>2015-10-25 22:42:22 +0000
committerJeremy Harris <jgh146exb@wizmail.org>2015-10-25 22:42:22 +0000
commitec0eb1a387b88e6ddd3f1f9ba6ffad6422b7298a (patch)
tree7d24deb292cce21b39a47870e82fc6eb49f58a73
parent0f557e9065b0bcfce38ee1fea5fc947bf0c5431c (diff)
Pipe transport: fix log_defer_output option. Bug 840
-rw-r--r--doc/doc-txt/ChangeLog2
-rw-r--r--src/src/deliver.c2
-rw-r--r--test/confs/061244
-rw-r--r--test/log/06123
-rw-r--r--test/scripts/0000-Basic/06126
5 files changed, 56 insertions, 1 deletions
diff --git a/doc/doc-txt/ChangeLog b/doc/doc-txt/ChangeLog
index 4fb36643e..abdc5b7cb 100644
--- a/doc/doc-txt/ChangeLog
+++ b/doc/doc-txt/ChangeLog
@@ -58,6 +58,8 @@ JH/08 Bug 1586: exiqgrep now refuses to run if there are unexpected arguments.
JH/09 Bug 1700: ignore space & tab embedded in base64 during decode.
+JH/10 Bug 840: fix log_defer_output option of pipe transport
+
Exim version 4.86
-----------------
diff --git a/src/src/deliver.c b/src/src/deliver.c
index 87f9cfb06..3dfa84261 100644
--- a/src/src/deliver.c
+++ b/src/src/deliver.c
@@ -1929,7 +1929,7 @@ address. This feature is not available for shadow transports. */
if ( !shadowing
&& ( tp->return_output || tp->return_fail_output
- || tp->log_output || tp->log_fail_output
+ || tp->log_output || tp->log_fail_output || tp->log_defer_output
) )
{
uschar *error;
diff --git a/test/confs/0612 b/test/confs/0612
new file mode 100644
index 000000000..773045752
--- /dev/null
+++ b/test/confs/0612
@@ -0,0 +1,44 @@
+# Exim test configuration 0612
+# log_defer_output on pipe transport
+
+exim_path = EXIM_PATH
+host_lookup_order = bydns
+primary_hostname = myhost.test.ex
+spool_directory = DIR/spool
+log_file_path = DIR/spool/log/%slog
+gecos_pattern = ""
+gecos_name = CALLER_NAME
+
+# ----- Main settings -----
+
+log_selector = +received_recipients
+
+#acl_smtp_rcpt = accept
+
+# ----- Routers -----
+
+begin routers
+
+client:
+ driver = accept
+ transport = pipe
+
+# ----- Transports -----
+
+begin transports
+
+pipe:
+ driver = pipe
+ temp_errors = *
+ command = perl -e "print 'Hi from pipe'; exit 5;"
+ log_defer_output = true
+
+# ----- Retry -----
+
+
+begin retry
+
+* * F,1h,10m
+
+
+# End
diff --git a/test/log/0612 b/test/log/0612
new file mode 100644
index 000000000..447c0f8ae
--- /dev/null
+++ b/test/log/0612
@@ -0,0 +1,3 @@
+1999-03-02 09:44:33 10HmaX-0005vi-00 <= CALLER@myhost.test.ex U=CALLER P=local S=sss for a
+1999-03-02 09:44:33 10HmaX-0005vi-00 <a@myhost.test.ex>: pipe transport output: Hi from pipe
+1999-03-02 09:44:33 10HmaX-0005vi-00 == a@myhost.test.ex R=client T=pipe defer (0): Child process of pipe transport returned 5 from command: /bin/perl
diff --git a/test/scripts/0000-Basic/0612 b/test/scripts/0000-Basic/0612
new file mode 100644
index 000000000..27aa56feb
--- /dev/null
+++ b/test/scripts/0000-Basic/0612
@@ -0,0 +1,6 @@
+# log_defer_output on pipe transport
+#
+exim a
+****
+sleep 1
+no_msglog_check