Reduce memory leaks

Review Request #115983 - Created Feb. 23, 2014 and submitted

Information
Kevin Krammer
ki18n
master
Reviewers
kdeframeworks
ilic
Create the script engine as a QObject child of the interface and
delete all interfaces in KTranscriptImp's destructor.

valgrind --tool=memcheck ./ktranscripttest

before:


==10664== HEAP SUMMARY:
==10664==     in use at exit: 445,913 bytes in 2,753 blocks
==10664==   total heap usage: 27,995 allocs, 25,242 frees, 6,059,328 bytes allocated
==10664== 
==10664== LEAK SUMMARY:
==10664==    definitely lost: 0 bytes in 0 blocks
==10664==    indirectly lost: 0 bytes in 0 blocks
==10664==      possibly lost: 1,488 bytes in 3 blocks
==10664==    still reachable: 444,425 bytes in 2,750 blocks
==10664==         suppressed: 0 bytes in 0 blocks


after: 

==11788== HEAP SUMMARY:
==11788==     in use at exit: 13,778 bytes in 66 blocks
==11788==   total heap usage: 28,003 allocs, 27,937 frees, 6,064,040 bytes allocated
==11788== 
==11788== LEAK SUMMARY:
==11788==    definitely lost: 0 bytes in 0 blocks
==11788==    indirectly lost: 0 bytes in 0 blocks
==11788==      possibly lost: 1,488 bytes in 3 blocks
==11788==    still reachable: 12,290 bytes in 63 blocks
==11788==         suppressed: 0 bytes in 0 blocks
All tests still run successfully
Kevin Krammer
Kevin Krammer
Chusslove Illich
Commit Hook
This review has been submitted with commit b0a60d0feb2dcac7af5f921be830bc4d9b9d3d18 by Kevin Krammer to branch master.
Kevin Krammer
Review request changed

Status: Closed (submitted)

Loading...