| 1 | #! /usr/bin/env perl |
| 2 | |
| 3 | # A test script that reads a message and resubmits it to Exim (having |
| 4 | # notionally checked it - but there's no checking here). This version |
| 5 | # uses BSMTP for input and output. |
| 6 | |
| 7 | # The number of the test is in the only argument - so we can call Exim |
| 8 | # with the appropriate configuration file. |
| 9 | |
| 10 | ($dir,$caller) = @ARGV; |
| 11 | |
| 12 | $cmd = |
| 13 | "$dir/eximdir/exim -C $dir/test-config -DCALLER=$caller -DDIR=$dir " . |
| 14 | "-DEXIM_PATH=$dir/eximdir/exim -odi -bS -oMr scanned-ok"; |
| 15 | |
| 16 | open(OUT, "|$cmd") || die "Failed to set up Exim process\n"; |
| 17 | print OUT while (<STDIN>); |
| 18 | close(OUT); |
| 19 | |
| 20 | # End |