Change: Authenticate only if $NNTPUser is set.
Signed-off-by: Thomas Hochstein <thh@inter.net>
This commit is contained in:
parent
dbca4ad8a1
commit
d69ba0bb34
|
@ -305,7 +305,7 @@ sub post {
|
||||||
my $NewsConnection = Net::NNTP->new($NNTPServer, Reader => 1)
|
my $NewsConnection = Net::NNTP->new($NNTPServer, Reader => 1)
|
||||||
or die "$0: E: Can't connect to news server '$NNTPServer'!\n";
|
or die "$0: E: Can't connect to news server '$NNTPServer'!\n";
|
||||||
|
|
||||||
$NewsConnection->authinfo ($NNTPUser, $NNTPPass);
|
$NewsConnection->authinfo ($NNTPUser, $NNTPPass) if (defined($NNTPUser));
|
||||||
$NewsConnection->post();
|
$NewsConnection->post();
|
||||||
$NewsConnection->datasend (@$ArticleR);
|
$NewsConnection->datasend (@$ArticleR);
|
||||||
$NewsConnection->dataend();
|
$NewsConnection->dataend();
|
||||||
|
|
Loading…
Reference in a new issue