Possible memory leak in TppPDFDevice.OutputStream?
Hello,
I'm using a the TppPDFDevice and the OutputStream property to generate a batch of PDF files at the server side. However my application seems to have a memory leak even after I free the TMemorySteam object used to get the result from PrintToDevices.
I do reuse the TppReport to generated several PDF, but make sure the TMemoryStream get release everytime.
Does TppReport/TppPDFDevice makes an internal copy of the Steam assigned at OutputStream that should be cleared?
I'm using RB 18.0 Build 369 with Delphi 10.1 Berlin.
I'm using a the TppPDFDevice and the OutputStream property to generate a batch of PDF files at the server side. However my application seems to have a memory leak even after I free the TMemorySteam object used to get the result from PrintToDevices.
I do reuse the TppReport to generated several PDF, but make sure the TMemoryStream get release everytime.
Does TppReport/TppPDFDevice makes an internal copy of the Steam assigned at OutputStream that should be cleared?
I'm using RB 18.0 Build 369 with Delphi 10.1 Berlin.
Comments
You are using an outdated version of ReportBuilder. Please update to the latest version and re-test.
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
Do you mean this might by a bug that got fixed in more recent version?
Regards,
Mario
I just upgrade to the lastest version of RB (21.02) and the above mentioned leak is still present. Any advice?
Regards,
Mario
Thank you for upgrading. In my quick testing, exporting a PDF file to a memory stream did not show any memory leaks using FastMM.
1. How are you detecting a memory leak? Are you using FastMM or another memory manager? What message does the leak detection software give?
2. Are you able to recreate this with a simple application using only RB and Delphi components? If so, please send the example in .zip format to support@digital-metaphors.com and I'll research a solution.
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com