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 2005/09/17 15:05:49 UTC

[Bug 4589] New: GLOB referance in Mail/SpamAssassin/Message.pm

http://bugzilla.spamassassin.org/show_bug.cgi?id=4589

           Summary: GLOB referance in Mail/SpamAssassin/Message.pm
           Product: Spamassassin
           Version: 3.1.0
          Platform: Sun
        OS/Version: Solaris
            Status: NEW
          Severity: normal
          Priority: P5
         Component: Libraries
        AssignedTo: dev@spamassassin.apache.org
        ReportedBy: davidb@chelsea.net


On line 126 in Mail/SpamAssassin/Message.pm, you check for GLOB to see if a
handle is passed.  Unfortunately, if you pass an IO::File, it fails.  Very
simple change suggested:

  if (ref $message eq 'ARRAY') {
     @message = @{$message};
  }
  elsif (ref $message =~ 'GLOB') {
    if (defined fileno $message) {
      @message = <$message>;
    }
  }

to change from eq to =~ so it matches any GLOB type passed in.



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

[Bug 4589] GLOB referance in Mail/SpamAssassin/Message.pm

Posted by bu...@bugzilla.spamassassin.org.
http://bugzilla.spamassassin.org/show_bug.cgi?id=4589





------- Additional Comments From davidb@chelsea.net  2005-09-17 08:20 -------
Umm...well, third time's the charm.  The "GLOB" doesn't show up in a IO::File
object, so some variation on this theme:

  elsif ((ref $message) =~ /GLOB|IO::/) {
    if (defined fileno $message) {
      @message = <$message>;
    }
  }



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

[Bug 4589] GLOB referance in Mail/SpamAssassin/Message.pm

Posted by bu...@bugzilla.spamassassin.org.
http://bugzilla.spamassassin.org/show_bug.cgi?id=4589





------- Additional Comments From davidb@chelsea.net  2005-09-17 06:10 -------
That line should read:

  elsif (ref $message =~ /GLOB/) {

...sorry.



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

[Bug 4589] GLOB referance in Mail/SpamAssassin/Message.pm

Posted by bu...@bugzilla.spamassassin.org.
http://bugzilla.spamassassin.org/show_bug.cgi?id=4589


felicity@apache.org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Severity|normal                      |enhancement
             Status|NEW                         |RESOLVED
         OS/Version|Solaris                     |All
           Platform|Sun                         |All
         Resolution|                            |FIXED
   Target Milestone|Undefined                   |3.2.0




------- Additional Comments From felicity@apache.org  2005-09-18 14:20 -------
Since this is pretty trivial, I added in my own version and committed it: r289976. :)



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