wxFile::Open(write_append) will create file if it doesn't exist

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_2_BRANCH@7551 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2000-06-09 15:49:59 +00:00
parent d26a990438
commit 59277cb364
2 changed files with 3 additions and 2 deletions

View File

@@ -52,7 +52,8 @@ or test if it can be opened for writing with Access()}
\twocolitem{{\bf wxFile::read\_write}}{Open file for reading and writing; can not be used with Access()}
\twocolitem{{\bf wxFile::write\_append}}{Open file for appending: the file is opened for writing, but the old
contents of the file is not erased and the file pointer is initially placed at the end of the file;
can not be used with Access()}
can not be used with Access(). This is the same as {\bf wxFile::write} if the
file doesn't exist.}
\end{twocollist}
Other constants defined elsewhere but used by wxFile functions are wxInvalidOffset which represents an

View File

@@ -221,7 +221,7 @@ bool wxFile::Open(const wxChar *szFileName, OpenMode mode, int accessMode)
break;
case write_append:
flags |= O_WRONLY | O_APPEND;
flags |= O_WRONLY | O_CREAT | O_APPEND;
break;
case read_write: