TIdSMTP leaks?

delphi package - automated exception handling
Post Reply
user1
Posts: 12
Joined: Tue Apr 09, 2013 6:58 pm

TIdSMTP leaks?

Post by user1 »

I've got a problem and I made a simple test to reproduce it. The following code leaks memory.

Code: Select all

TIdSMTP *SMTP;
void __fastcall TForm1::FormCreate(TObject *Sender)
{
	SMTP = new TIdSMTP(this);
}
void __fastcall TForm1::FormDestroy(TObject *Sender)
{
	delete SMTP;
}
Is that a true memory leak? The leak happens in TIdMessageClient.InitComponent when executing this line:

Code: Select all

  FMsgLineFold := TAB;
Interesting thing though, if I add TIdSMTP to the form at design time, no leaks detected (present).
madshi
Site Admin
Posts: 10764
Joined: Sun Mar 21, 2004 5:25 pm

Re: TIdSMTP leaks?

Post by madshi »

I don't really have the resources to debug all reported leaks in any VCL or 3rd party component to check if it's a legit leak or not. Usually the leak reports seem to be quite accurate, but I can't guarantee that there will never be false positives. If you're sure that a specific reported leak is a false positive I might look into it, but if it ends up being a true leak I'll not be very happy about it. I can't afford to go chasing bugs in other people's software. Have to be honest about it. Too many things on my to do list already... :wink:
Post Reply