[fpc-pascal] help with synapse mime routines...

waldo kitty wkitty42 at windstream.net
Thu Feb 17 04:10:47 CET 2011


so i take it, from the dearth of replies, that no one on this list uses synapse 
or its mime library?

i've reduced/stripped the code to produce the attached .pas file... while i now 
do not get a line number any more (which i also do not understand), at least i 
can more easily see now that the problem is associated with freeing the second 
(last??) instance of the created m1 var... i'm working with an email message 
that is multipart with a text/plain part first and a text/html part second... i 
don't currently have a three part multipart message to work with and for this 
application, it is doubtful that one will appear but it would be best to code 
for the possibility i think... my goal is to extract only the text/plain portion 
and decode any mime'd characters to CP850 ascii equivalents... no, not 7-bit but 
8-bit if necessary... an example is decoding = 9 9 (that's equal nine nine 
without the spaces) to "(tm)" (that's open parens, Tee, Emm, close parens)...

can anyone assist with the reason for the exception?? i'm using the last release 
code of synapse (download zip archive) with FPC 2.4.3... currently on win32...

here's the screen output for the attached code...

C:\freepascal\projects\arnews>tstmime1 arnews4.req

   entering ProcessParts...
     allocate m1 for part 1
     assign m1.OnWalkPart for part 1
     pulling part 1 into m1-1
     ** WE HAVE A TEXT/PLAIN SECTION **
     finally
       free m1 for part 1...
         m1 <> NIL... Destroying... done!
     done!

     allocate m1 for part 2
     assign m1.OnWalkPart for part 2
     pulling part 2 into m1-2
     This part is not TEXT/PLAIN... DELETING...
       firing m.DeleteSubPart(1
       back from m.DeleteSubPart...
     Done!
     finally
       free m1 for part 2...
         m1 <> NIL... Destroying... An unhandled exception occurred at $6275736E
:
EAccessViolation : Access violation
   $6275736E
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: tstmime1.pas
URL: <http://lists.freepascal.org/pipermail/fpc-pascal/attachments/20110216/0d5450d3/attachment.ksh>


More information about the fpc-pascal mailing list