panic() when a page that is still mapped is freed.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30606 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Ingo Weinhold
2009-05-03 12:37:51 +00:00
parent 88b29adcbd
commit a866fa9466
+6 -2
View File
@@ -770,8 +770,12 @@ set_page_state_nolock(vm_page *page, int pageState)
if (sPageDeficit > 0)
sFreePageCondition.NotifyOne();
if (pageState != PAGE_STATE_INACTIVE && page->cache != NULL)
panic("to be freed page %p has cache", page);
if (pageState != PAGE_STATE_INACTIVE) {
if (page->cache != NULL)
panic("to be freed page %p has cache", page);
if (!page->mappings.IsEmpty() || page->wired_count > 0)
panic("to be freed page %p has mappings", page);
}
}
if (page->cache != NULL && page->cache->temporary) {
if (pageState == PAGE_STATE_MODIFIED)