[rt-users] Dealing with Quoted-Printable?

System Administrator sysadmin at ff-muenchen.de
Wed Aug 23 12:03:33 EDT 2000


On Wed, 23 Aug 2000, Jesse wrote:

> It actually came up a year or so ago. I believe the hack is 
> to modify lib/rt/ui/mail/manipulate.pm
> It appears that MIME::Word (part of the MIME::Entity package can do the decoding.
> If anyone wants to submit a patch for 1.0 that _doesn't_ drag in all of MIME::Entity as a dependency (though that's what we do in RT2) I'd be happy to include
> it in .1.0.5

Thanks for the info.  I've changed it as suggested--but I didn't had the
time to make it independent of MIME::Word.  (I've installed this Perl
module on my system so the dependency isn't an issue for me.  I can
understand if you don't want to include the patch as is but maybe the
patch can be helpful for others on the list too.  In fact, installing
MIME::* isn't such a big problem...)

The patch is attached (apply to lib/rt/ui/mail/manipulate.pm).  Hints to
improve this are always welcomed!


Cheers,

Chris
--
F&F Computer Anwendungen        Tel: 089/51727-0
und Unternehmensberatung GmbH   Fax: 089/51727-111
Westendstr. 195                 Mail:C.Schwarz at ff-muenchen.de
D-80686 Muenchen                http://www.ff-muenchen.de
-------------- next part --------------
--- manipulate.pm.orig	Wed Aug 23 17:50:46 2000
+++ manipulate.pm	Wed Aug 23 17:51:49 2000
@@ -1,5 +1,7 @@
 package rt::ui::mail::manipulate;
 
+use MIME::Words;
+
 sub activate {
   
   #uncomment for a debugging version
@@ -115,6 +117,11 @@
   ($headers, $body) = split (/\n\n/, $content, 2);
 
   foreach $line (split (/\n(?!\s)/,$headers)) {
+
+    # CS-20000823
+    if ($line =~/^Subject:/o) {
+      $line = MIME::Words::decode_mimewords($line);
+    }
     
     if ($line =~/^X-RT-Loop-Prevention: $rt::rtname/g) {
       die ("RT has recieved mail from itself. Goodnight.");


More information about the rt-users mailing list