Hi,
it seems there is a memory leak when using TTeeGDIPlus. It can be reproduced in the sample project (Delphi 2010) I've attached.
Just run the code and then resize the form a couple of times and then close it. I've also attached a screenshot of the FastMM report that pops up.
I think it's caused by TGDIPlusCanvas.InitWindow() which is called by the draw routine.
It creates a TTeeCanvas3D object each time it is called but doesn't free it
...
begin
IXORCanvas:=TTeeCanvas3D.Create;
Could you please take a look at it?
Regards,
Amadeus
Memory leak when using TTeeGDIPlus
Memory leak when using TTeeGDIPlus
- Attachments
-
- GDIPlusMemLeak.7z
- (28.35 KiB) Downloaded 240 times
Re: Memory leak when using TTeeGDIPlus
While I'm at it: seems there's another one in Chart.pas ->TLegendSymbol.Draw()
OldBrush:=TBrush.Create;
OldBrush doesn't get freed.
OldBrush:=TBrush.Create;
OldBrush doesn't get freed.
Re: Memory leak when using TTeeGDIPlus
Hi Amadeus,
You are right. I could reproduce it so I've added it to the defect list to be revised in future releases (TV52014961).
Thanks for reporting it.
You are right. I could reproduce it so I've added it to the defect list to be revised in future releases (TV52014961).
Thanks for reporting it.
Best Regards,
Yeray Alonso Development & Support Steema Software Av. Montilivi 33, 17003 Girona, Catalonia (SP) | |
Please read our Bug Fixing Policy |
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Re: Memory leak when using TTeeGDIPlus
Hi Amadeus,
Yes, we found that some weeks ago and fixed it for the next maintenance release.While I'm at it: seems there's another one in Chart.pas ->TLegendSymbol.Draw()
OldBrush:=TBrush.Create;
OldBrush doesn't get freed.
Best Regards,
Narcís Calvet / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Re: Memory leak when using TTeeGDIPlus
Hi Amadeus,
Just wanted to let you know that TV52014961 has been fixed for the next maintenance release. To fix this you can add line below to GDI+ canvas constructor (TGDIPlusCanvas.Create) and remove it from TGDIPlusCanvas.InitWindow.
Just wanted to let you know that TV52014961 has been fixed for the next maintenance release. To fix this you can add line below to GDI+ canvas constructor (TGDIPlusCanvas.Create) and remove it from TGDIPlusCanvas.InitWindow.
Code: Select all
IXORCanvas:=TTeeCanvas3D.Create;
Best Regards,
Narcís Calvet / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |
Re: Memory leak when using TTeeGDIPlus
Yes, this does the trick.
Thanks for the quick help. It's appreciated
Thanks for the quick help. It's appreciated
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Re: Memory leak when using TTeeGDIPlus
Kubach,
You're very welcome. Thanks for your feedback too!
You're very welcome. Thanks for your feedback too!
Best Regards,
Narcís Calvet / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |