You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@spamassassin.apache.org by bu...@bugzilla.spamassassin.org on 2006/03/11 19:15:54 UTC

[Bug 4825] New: Mail::SpamAssassin::Client::ping always returns 0

http://issues.apache.org/SpamAssassin/show_bug.cgi?id=4825

           Summary: Mail::SpamAssassin::Client::ping always returns 0
           Product: Spamassassin
           Version: 3.1.0
          Platform: Other
        OS/Version: other
            Status: NEW
          Severity: normal
          Priority: P5
         Component: Libraries
        AssignedTo: dev@spamassassin.apache.org
        ReportedBy: felicity@apache.org


>From http://rt.cpan.org/Ticket/Display.html?id=18124:

There is a bug in /usr/lib/perl5/site_perl/5.8.5/Mail/SpamAssassin/Client.pm

In function "ping". The function always returns "0" - even if it can
ping SpamAssassin.

The reason is there:

return 0 unless ($resp_msg eq 'PONG'); (line 425)

$resp_msg is something like "PONG\n" - so, the test fails. You can solve
the problem for example this way:

return 0 unless ($resp_msg =~ '^PONG');

Regards
   Tony



------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

[Bug 4825] Mail::SpamAssassin::Client::ping always returns 0

Posted by bu...@bugzilla.spamassassin.org.
http://issues.apache.org/SpamAssassin/show_bug.cgi?id=4825





------- Additional Comments From parkerm@pobox.com  2006-05-29 14:52 -------
Created an attachment (id=3527)
 --> (http://issues.apache.org/SpamAssassin/attachment.cgi?id=3527&action=view)
Trivial Patch




------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

[Bug 4825] [review] Mail::SpamAssassin::Client::ping always returns 0

Posted by bu...@bugzilla.spamassassin.org.
http://issues.apache.org/SpamAssassin/show_bug.cgi?id=4825


parkerm@pobox.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|Mail::SpamAssassin::Client::|[review]
                   |ping always returns 0       |Mail::SpamAssassin::Client::
                   |                            |ping always returns 0
   Target Milestone|Undefined                   |3.1.3




------- Additional Comments From parkerm@pobox.com  2006-05-29 14:53 -------
Fixed in trunk, pretty trivial but putting up for review for 3.1.X anyway.



------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

[Bug 4825] [discuss] Mail::SpamAssassin::Client::ping always returns 0

Posted by bu...@bugzilla.spamassassin.org.
http://issues.apache.org/SpamAssassin/show_bug.cgi?id=4825


felicity@apache.org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|[review]                    |[discuss]
                   |Mail::SpamAssassin::Client::|Mail::SpamAssassin::Client::
                   |ping always returns 0       |ping always returns 0
  Status Whiteboard|ready                       |
   Target Milestone|3.1.4                       |3.2.0




------- Additional Comments From felicity@apache.org  2006-06-30 03:04 -------
ok, fixed in 3.1:

Sending        lib/Mail/SpamAssassin/Client.pm
Transmitting file data .
Committed revision 418169.

moving to 3.2 milestone to discuss the s/// idea...



------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

[Bug 4825] [review] Mail::SpamAssassin::Client::ping always returns 0

Posted by bu...@bugzilla.spamassassin.org.
http://issues.apache.org/SpamAssassin/show_bug.cgi?id=4825





------- Additional Comments From jm@jmason.org  2006-06-29 09:23 -------
+1.  I'd prefer not to do the s/// thing without a bit more thought, since it
might have knock-on effects elsewhere -- maybe for trunk.  for 3.1.x I'm happy
with this patch.



------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

[Bug 4825] [review] Mail::SpamAssassin::Client::ping always returns 0

Posted by bu...@bugzilla.spamassassin.org.
http://issues.apache.org/SpamAssassin/show_bug.cgi?id=4825


felicity@apache.org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|3.1.3                       |3.1.4






------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

[Bug 4825] [review] Mail::SpamAssassin::Client::ping always returns 0

Posted by bu...@bugzilla.spamassassin.org.
http://issues.apache.org/SpamAssassin/show_bug.cgi?id=4825





------- Additional Comments From felicity@apache.org  2006-06-01 16:20 -------
Hrm.

I'm +1 on this, though I wonder if we shouldn't just always get rid of the trailing CRLF instead?  ala:

--- lib/Mail/SpamAssassin/Client.pm     (revision 410868)
+++ lib/Mail/SpamAssassin/Client.pm     (working copy)
@@ -482,6 +482,7 @@
 sub _parse_response_line {
   my ($self, $line) = @_;
 
+  $line =~ s/\r?\n$//;
   return split(/\s+/, $line, 3);
 }




------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

[Bug 4825] Mail::SpamAssassin::Client::ping always returns 0

Posted by bu...@bugzilla.spamassassin.org.
http://issues.apache.org/SpamAssassin/show_bug.cgi?id=4825


parkerm@pobox.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |parkerm@pobox.com






------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

[Bug 4825] [discuss] Mail::SpamAssassin::Client::ping always returns 0

Posted by bu...@bugzilla.spamassassin.org.
http://issues.apache.org/SpamAssassin/show_bug.cgi?id=4825


felicity@apache.org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |FIXED




------- Additional Comments From felicity@apache.org  2006-09-05 20:33 -------
(In reply to comment #7)
> if you want to do the s/// thing in trunk, go ahead... we have plenty of time to
> run into any issues it might bring up, given the stage of the dev cycle 3.2.0
is in.

sure, done:

Sending        SpamAssassin/Client.pm
Transmitting file data .
Committed revision 440475.




------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

[Bug 4825] [discuss] Mail::SpamAssassin::Client::ping always returns 0

Posted by bu...@bugzilla.spamassassin.org.
http://issues.apache.org/SpamAssassin/show_bug.cgi?id=4825





------- Additional Comments From jm@jmason.org  2006-09-05 14:51 -------
if you want to do the s/// thing in trunk, go ahead... we have plenty of time to
run into any issues it might bring up, given the stage of the dev cycle 3.2.0 is in.



------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

[Bug 4825] [review] Mail::SpamAssassin::Client::ping always returns 0

Posted by bu...@bugzilla.spamassassin.org.
http://issues.apache.org/SpamAssassin/show_bug.cgi?id=4825


spamassassin@dostech.ca changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Status Whiteboard|                            |needs 1 vote




------- Additional Comments From spamassassin@dostech.ca  2006-05-30 00:07 -------
+1



------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

[Bug 4825] [review] Mail::SpamAssassin::Client::ping always returns 0

Posted by bu...@bugzilla.spamassassin.org.
http://issues.apache.org/SpamAssassin/show_bug.cgi?id=4825


jm@jmason.org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Status Whiteboard|needs 1 vote                |ready






------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.