Re: TIdMessage SaveToStream bug?

Giganews Newsgroups
Subject: Re: TIdMessage SaveToStream bug?
Posted by:  Serge Dosyukov (serge[AT]argosoftware[DOT]com)
Date: Mon, 5 Apr 2004

Yes, it is a bug of D7
Did you reinstall Indy, then use Dev build
If do not need access to a component after SaveToFile just leave it, it will
be destroied
If you need a component itself, then you need to reimplement method yourself

an article about sending E-Mails using INDY in D7/D8 will be available soon
on BDN and on my web-site
"up-to-D7" version and sample will be available tonight from here

Link is not activated yet, but it will be tonight

Serge Dosyukov
Borland Delphi product certified
Microsoft Certified Professional

"Koller Krisztian" <koll…> wrote in message
> I'd like to save a message by SaveToFile method.
> I get an acccess violation error:
> //TIdMessage.SaveToFile:
>  ...
>  vStream := TFileStream.create(AFileName, fmCreate);
>  try
>    SaveToStream(vStream, AHeadersOnly);  //saving is correct
>  finally
>    vStream.Free;    //access violation
>  end;
> I've debugged TIdMessage: before calls SaveToStream, FHandle of vStream
> equals 1552, after calling FHandle is 12.
> I think this is the reason of the problem. I didn't find any problem in
> SaveToStream method...
> How can I solve it?
> (D7 + newest Indy)
> Thanks,
> Chris


In response to

TIdMessage SaveToStream bug? posted by Koller Krisztian on Mon, 5 Apr 2004