#pragma hdrstop
#endif
-#ifndef WX_PRECOMP
- #include "wx/defs.h"
-#endif
-
#if wxUSE_STREAMS && wxUSE_FILE
#include <stdio.h>
-#include <wx/stream.h>
-#include <wx/wfstream.h>
+#include "wx/stream.h"
+#include "wx/wfstream.h"
// ----------------------------------------------------------------------------
// wxFileInputStream
size_t wxFileOutputStream::OnSysWrite(const void *buffer, size_t size)
{
size_t ret = m_file->Write(buffer, size);
- m_lasterror = wxStream_EOF; // TODO
+ if (m_file->Error())
+ m_lasterror = wxStream_WRITE_ERR;
+ else
+ m_lasterror = wxStream_NOERROR;
return ret;
}