D
David Dyer-Bennet
With Perl 5.6.1 on Linux.
The following statement is driving me crazy:
if (! open (FH, "|-", "qmail-inject", "-a", "dd-b\@dd-b.net")) {
die "failed to open";
}
I get the error:
Can't use an undefined value as filehandle reference
at ./t.pl line 13.
(test and production cases are being run with use strict and use
warnings).
qmail-inject is in the path. If I turn this into the two-arg form of
open, IT WORKS. (I don't want to do that in the production version
because of quoting/parsing issues with the args; that last email
address will actually be a list taken from an array).
I'm overlooking something obvious; I can smell it, but I can't find
what it *is*.
This should be a slam-dunk for somebody. What am I overlooking?
The following statement is driving me crazy:
if (! open (FH, "|-", "qmail-inject", "-a", "dd-b\@dd-b.net")) {
die "failed to open";
}
I get the error:
Can't use an undefined value as filehandle reference
at ./t.pl line 13.
(test and production cases are being run with use strict and use
warnings).
qmail-inject is in the path. If I turn this into the two-arg form of
open, IT WORKS. (I don't want to do that in the production version
because of quoting/parsing issues with the args; that last email
address will actually be a list taken from an array).
I'm overlooking something obvious; I can smell it, but I can't find
what it *is*.
This should be a slam-dunk for somebody. What am I overlooking?