[GRASS-SVN] r43073 - grass/trunk/lib/vector/Vlib
svn_grass at osgeo.org
svn_grass at osgeo.org
Thu Aug 12 13:23:15 EDT 2010
Author: mmetz
Date: 2010-08-12 17:23:15 +0000 (Thu, 12 Aug 2010)
New Revision: 43073
Modified:
grass/trunk/lib/vector/Vlib/open_nat.c
Log:
avoid struct stat
Modified: grass/trunk/lib/vector/Vlib/open_nat.c
===================================================================
--- grass/trunk/lib/vector/Vlib/open_nat.c 2010-08-12 17:22:28 UTC (rev 43072)
+++ grass/trunk/lib/vector/Vlib/open_nat.c 2010-08-12 17:23:15 UTC (rev 43073)
@@ -93,7 +93,6 @@
int V1_open_new_nat(struct Map_info *Map, const char *name, int with_z)
{
char buf[1000];
- struct stat info;
G_debug(1, "V1_open_new_nat(): name = %s", name);
@@ -121,7 +120,7 @@
* Vect_open_new(): remove this check ? */
/* check to see if dig_plus file exists and if so, remove it */
G__file_name(name_buf, buf, GV_TOPO_ELEMENT, G_mapset());
- if (stat(name_buf, &info) == 0) /* file exists? */
+ if (access(name_buf, F_OK) == 0) /* file exists? */
unlink(name_buf);
G__file_name(name_buf, buf, GV_COOR_ELEMENT, G_mapset());
More information about the grass-commit
mailing list