Avoid leaking memory under certain conditions
commit37b0f8b15449c52c7665ccaf39c26cab65dbcff6
authormalc <av1474@comtv.ru>
Tue, 30 Oct 2012 00:31:19 +0000 (30 04:31 +0400)
committermalc <av1474@comtv.ru>
Tue, 30 Oct 2012 00:31:19 +0000 (30 04:31 +0400)
treeac5d020ac38e56435bc8625140567b2af7f94a6b
parent8e89dee0521d48444e56da8fd2c62dfc17f0f3c6
Avoid leaking memory under certain conditions

When document is loaded pages that are already rendered are not
immediately freed, futhermore the eviction will not happen given that
old pages occupy the same spot and are not considered as eviction
targets, generation count is not checked and even if it was eviting
old page with the new underlying document can be unsafe (depends on
how the underlying rendering engine is implemented), so the safest way
to deal with it is to just flush them en masse.
main.ml