summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
64c177c)
- to prevent dupes being normally filtered by sendmail(8)
-my @rcpts=(@addr ? @addr : (undef())); # !defined($rcpt) if we have no recipients
+# !defined($rcpt) if we have no recipients
+# make the list unique to prevent dupes being normally filtered by sendmail(8)
+# one '{' is block-wrapper, another '{' is hash-indirection!
+my @rcpts=keys(%{{ map(($_=>1),(@addr ? @addr : (undef()))) }});
+
my $stdin_body=(@rcpts<=1 ? undef() : do { # store input data only if it will be used multiple times
local $/=undef();
<STDIN>;
my $stdin_body=(@rcpts<=1 ? undef() : do { # store input data only if it will be used multiple times
local $/=undef();
<STDIN>;