// headers
// ----------------------------------------------------------------------------
-#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA)
- #pragma implementation "file.h"
-#endif
-
// For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
wxLogSysError(_("can't create file '%s'"), szFileName);
return false;
}
- else
- {
- Attach(fd);
- return true;
- }
+
+ Attach(fd);
+ return true;
}
// open the file
wxLogSysError(_("can't open file '%s'"), szFileName);
return false;
}
- else {
- Attach(fd);
- return true;
- }
+
+ Attach(fd);
+ return true;
}
// close
// flush
bool wxFile::Flush()
{
-#if defined(__VISUALC__) || defined(HAVE_FSYNC)
+#ifdef HAVE_FSYNC
// fsync() only works on disk files and returns errors for pipes, don't
// call it then
if ( IsOpened() && GetKind() == wxFILE_KIND_DISK )
return false;
}
}
-#endif // fsync
+#endif // HAVE_FSYNC
return true;
}