fix for opening files with VC++ 8 (closes bug 994337)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@28341 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -345,6 +345,13 @@ bool wxFile::Open(const wxChar *szFileName, OpenMode mode, int accessMode)
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef __WINDOWS__
|
||||||
|
// only read/write bits for "all" are supported by this function under
|
||||||
|
// Windows, and VC++ 8 returns EINVAL if any other bits are used in
|
||||||
|
// accessMode, so clear them as they have at best no effect anyhow
|
||||||
|
accessMode &= wxS_IRUSR | wxS_IWUSR;
|
||||||
|
#endif // __WINDOWS__
|
||||||
|
|
||||||
int fd = wxOpen( szFileName, flags ACCESS(accessMode));
|
int fd = wxOpen( szFileName, flags ACCESS(accessMode));
|
||||||
#endif
|
#endif
|
||||||
if ( fd == -1 )
|
if ( fd == -1 )
|
||||||
|
Reference in New Issue
Block a user