mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-07-20 12:45:50 +03:00
In test it should be taken into account that lappend listmem [meminfo h] checktrend $listmem 0 0 "Memory leak" also gets memory (also about 100 bytes per iteration).
20 lines
484 B
Plaintext
20 lines
484 B
Plaintext
puts "==========="
|
|
puts "0031546: Application Framework - Memory leak (100 bytes) on Load / Close OCAF document"
|
|
puts "==========="
|
|
|
|
puts "Preparing empty document"
|
|
set docname ${imagedir}/${casename}.cbf
|
|
NewDocument D BinOcaf
|
|
SaveAs D $docname
|
|
Close D
|
|
|
|
puts "Executing Load / Close in cycle to see if allocated heap memory grows"
|
|
set listmem {}
|
|
for {set i 1} {$i < 10} {incr i} {
|
|
Open $docname D
|
|
Close D
|
|
|
|
lappend listmem [meminfo h]
|
|
checktrend $listmem 50 50 "Memory leak"
|
|
}
|