[GRASS-SVN] r31319 - grass/trunk/lib/init

svn_grass at osgeo.org svn_grass at osgeo.org
Sun May 11 15:21:43 EDT 2008


Author: glynn
Date: 2008-05-11 15:21:43 -0400 (Sun, 11 May 2008)
New Revision: 31319

Modified:
   grass/trunk/lib/init/gis_set.tcl
Log:
Don't use (broken) home-grown test for file existence



Modified: grass/trunk/lib/init/gis_set.tcl
===================================================================
--- grass/trunk/lib/init/gis_set.tcl	2008-05-11 19:16:33 UTC (rev 31318)
+++ grass/trunk/lib/init/gis_set.tcl	2008-05-11 19:21:43 UTC (rev 31319)
@@ -138,13 +138,11 @@
     } else {
         cdir $dir
         .frame0.frameNMS.second.entry configure -state disabled
-        foreach filename [lsort [glob -nocomplain *]] {
-            if {[string compare $filename "PERMANENT"] == 0} {
-                # All good locations have valid PERMANENT mapset.
-                if {[file exists "$dir/PERMANENT/DEFAULT_WIND"] != 0} {
-                    set found 1
-                    .frame0.frameNMS.second.entry configure -state normal
-                }
+        if {[file isdirectory "PERMANENT"]} {
+            # All good locations have valid PERMANENT mapset.
+            if {[file exists "$dir/PERMANENT/DEFAULT_WIND"] != 0} {
+                set found 1
+                .frame0.frameNMS.second.entry configure -state normal
             }
         }
     }



More information about the grass-commit mailing list