Division bug hidden, now only shows when 64-bit division is needed
[tpg/acess2.git] / Kernel / vfs / open.c
index d5e940e..552276d 100644 (file)
@@ -4,6 +4,7 @@
  */
 #define DEBUG  0
 #include <acess.h>
+#include <mm_virt.h>
 #include "vfs.h"
 #include "vfs_int.h"
 #include "vfs_ext.h"
@@ -651,6 +652,14 @@ void VFS_Close(int FD)
                return;
        }
        
+       #if VALIDATE_VFS_FUNCTIPONS
+       if(h->Node->Close && !MM_GetPhysAddr(h->Node->Close)) {
+               Log_Warning("VFS", "Node %p's ->Close method is invalid (%p)",
+                       h->Node, h->Node->Close);
+               return ;
+       }
+       #endif
+       
        if(h->Node->Close)
                h->Node->Close( h->Node );
        

UCC git Repository :: git.ucc.asn.au