[GRASS-SVN] r43279 - grass/trunk/lib/gis
svn_grass at osgeo.org
svn_grass at osgeo.org
Thu Aug 26 04:52:02 EDT 2010
Author: glynn
Date: 2010-08-26 08:52:01 +0000 (Thu, 26 Aug 2010)
New Revision: 43279
Modified:
grass/trunk/lib/gis/gisinit.c
Log:
Set _fmode = O_BINARY at startup; relying upon fmode.o doesn't work
for libraries loaded at run-time (e.g. ctypes).
Modified: grass/trunk/lib/gis/gisinit.c
===================================================================
--- grass/trunk/lib/gis/gisinit.c 2010-08-26 08:42:38 UTC (rev 43278)
+++ grass/trunk/lib/gis/gisinit.c 2010-08-26 08:52:01 UTC (rev 43279)
@@ -15,9 +15,10 @@
*/
#include <stdio.h>
-#include <unistd.h>
#include <stdlib.h>
#include <string.h>
+#include <unistd.h>
+#include <fcntl.h>
#include <sys/stat.h>
#include <locale.h>
@@ -112,6 +113,9 @@
static int gisinit(void)
{
+#ifdef __MINGW32__
+ _fmode = O_BINARY;
+#endif
/* Mark window as not set */
G__.window_set = 0;
More information about the grass-commit
mailing list