From 6c0957c21ac8df28004f97d409b1613ef99e603a Mon Sep 17 00:00:00 2001 From: David Rose Date: Mon, 21 Dec 2009 18:08:46 +0000 Subject: [PATCH] build win32 --- direct/src/plugin/p3dInstanceManager.cxx | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/direct/src/plugin/p3dInstanceManager.cxx b/direct/src/plugin/p3dInstanceManager.cxx index 90b01f2b44..af0f1c6bbf 100644 --- a/direct/src/plugin/p3dInstanceManager.cxx +++ b/direct/src/plugin/p3dInstanceManager.cxx @@ -35,6 +35,8 @@ #ifdef _WIN32 #include +#include // chmod() +#include // rmdir() #else #include #include @@ -1073,7 +1075,7 @@ delete_directory_recursively(const string &root_dir) { if (result == 0) { nout << "Deleted " << root_dir << "\n"; } else { - if (access(root_dir.c_str(), F_OK) == 0) { + if (access(root_dir.c_str(), 0) == 0) { nout << "Could not delete " << root_dir << "\n"; } } @@ -1123,7 +1125,7 @@ delete_directory_recursively(const string &root_dir) { if (result == 0) { nout << "Removed directory " << root_dir << "\n"; } else { - if (access(pathname.c_str(), F_OK) == 0) { + if (access(pathname.c_str(), 0) == 0) { nout << "Could not remove directory " << root_dir << "\n"; } }