BarryServer : Git

All the code for all my projects
// BarryServer : Git / Nucleus / commit / 665af0a43af0d406733bda816ca1a7b2f9184319 / memory / page.c

// Related

Nucleus

Barry Improved page fault handling and mmap system call 665af0a (3 years, 2 months ago)
diff --git a/memory/page.c b/memory/page.c
index 3aa4923..95b1548 100644
--- a/memory/page.c
+++ b/memory/page.c
@@ -6,6 +6,7 @@
 
 #include <nucleus/object.h>
 #include <nucleus/memory.h>
+#include "paging.h"
 #include "namespace.h"
 
 static void page_delete(Object *);
@@ -22,7 +23,8 @@ static void
 page_delete(Object *obj)
 {
 	Page *page = (void *) obj;
-	free_frame(PAGE_ADDR(page->frame));
+	if (page->frame != zeroFrame)
+		free_frame(PAGE_ADDR(page->frame));
 }
 
 /* Create a new Page entry */