[GRASS-SVN] r43076 - grass/trunk/lib/gis
svn_grass at osgeo.org
svn_grass at osgeo.org
Thu Aug 12 13:39:39 EDT 2010
Author: mmetz
Date: 2010-08-12 17:39:39 +0000 (Thu, 12 Aug 2010)
New Revision: 43076
Modified:
grass/trunk/lib/gis/tempfile.c
Log:
avoid struct stat
Modified: grass/trunk/lib/gis/tempfile.c
===================================================================
--- grass/trunk/lib/gis/tempfile.c 2010-08-12 17:33:18 UTC (rev 43075)
+++ grass/trunk/lib/gis/tempfile.c 2010-08-12 17:39:39 UTC (rev 43076)
@@ -73,7 +73,6 @@
char path[GPATH_MAX];
char name[GNAME_MAX];
char element[100];
- struct stat st;
if (pid <= 0)
pid = getpid();
@@ -84,7 +83,7 @@
sprintf(name, "%d.%d", pid, uniq);
G__file_name(path, element, name, G_mapset());
}
- while (stat(path, &st) == 0);
+ while (access(path, F_OK) == 0);
return G_store(path);
}
More information about the grass-commit
mailing list