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;
}