From d41fec74be04d13bd07adffe796c66cc52d8c4b7 Mon Sep 17 00:00:00 2001 From: "cebka@lenovo-laptop" Date: Mon, 15 Mar 2010 21:31:54 +0300 Subject: [PATCH] * Read 'END' after password command --- perl/lib/Mail/Rspamd/Client.pm | 3 +++ 1 file changed, 3 insertions(+) diff --git a/perl/lib/Mail/Rspamd/Client.pm b/perl/lib/Mail/Rspamd/Client.pm index dd09d4a2f..100bfad68 100644 --- a/perl/lib/Mail/Rspamd/Client.pm +++ b/perl/lib/Mail/Rspamd/Client.pm @@ -670,6 +670,9 @@ sub _auth { if (sysread($sock, $reply, 255)) { if ($reply =~ /^password accepted/) { + return 0 unless $self->_get_io_readiness($sock, 0); + # read "END" + sysread($sock, $reply, 255); return 1; } } -- 2.39.5