Fixed wrong dir test in Windows code in both 1.0 and 1.1 (thanks, Dennis!).
--- a/CHANGELOG Mon Oct 01 15:47:40 2007 +0000
+++ b/CHANGELOG Tue Dec 11 18:54:10 2007 +0000
@@ -4,6 +4,7 @@
-- stuff in the stable-1.0 branch, backported from 2.0.0 dev branch, etc ---
+12112007 - Fixed incorrect directory test in Windows code (thanks, Dennis!).
10012007 - More mingw32 fixes.
07122007 - Maybe fixed compile on mingw32.
07112007 - Fixed crash on zero-byte read/write (thanks, Ensiform!).
--- a/platform/win32.c Mon Oct 01 15:47:40 2007 +0000
+++ b/platform/win32.c Tue Dec 11 18:54:10 2007 +0000
@@ -970,7 +970,7 @@
int __PHYSFS_platformDelete(const char *path)
{
/* If filename is a folder */
- if (GetFileAttributes(path) == FILE_ATTRIBUTE_DIRECTORY)
+ if (GetFileAttributes(path) & FILE_ATTRIBUTE_DIRECTORY)
{
BAIL_IF_MACRO(!RemoveDirectory(path), win32strerror(), 0);
} /* if */