Memmory Leak - TextImage fields
Easy-to-use print report library and designer
Brought to you by:
aliks-os
Hello!
I found a memmory leak on the handling of TextImage fields. On sectionValueImage function you create a QImage with new and then pass it through as a reference and the pointer is never released.
Theres no need to dynamic allocation of QImage in this case so I suggest to change the function as follows:
QImage QtRPT::sectionValueImage(QString paramName) {
QImage paramValue;
paramName.replace("[","");
paramName.replace("]","");
emit setValueImage(m_recNo, paramName, paramValue, m_pageReport);
return paramValue;
}
Thank you, fixed it