[GRASS-SVN] r31010 - grass/trunk/gui/tcltk/gis.m

svn_grass at osgeo.org svn_grass at osgeo.org
Wed Apr 16 04:42:03 EDT 2008


Author: hamish
Date: 2008-04-16 04:42:03 -0400 (Wed, 16 Apr 2008)
New Revision: 31010

Modified:
   grass/trunk/gui/tcltk/gis.m/mapcanvas.tcl
Log:
give a hint as to what is wrong if g.region can't find libgdal

Modified: grass/trunk/gui/tcltk/gis.m/mapcanvas.tcl
===================================================================
--- grass/trunk/gui/tcltk/gis.m/mapcanvas.tcl	2008-04-15 17:10:05 UTC (rev 31009)
+++ grass/trunk/gui/tcltk/gis.m/mapcanvas.tcl	2008-04-16 08:42:03 UTC (rev 31010)
@@ -1131,11 +1131,11 @@
 				set parts($key) $value
 			}
 		}
-		
-		if {[catch {close $input} error]} {
-			GmLib::errmsg $error [G_msg "Error setting region"]
+
+		if { [catch {close $input} error] || ![info exists parts] } {
+			GmLib::errmsg $error [G_msg "Error setting region (Problem with g.region?)"]
 		}
-		
+
 		#set start point (sw corner)
 		set $parts(w) [expr round($parts(w)/$parts(ewres))*$parts(ewres)]
 		set $parts(s) [expr round($parts(s)/$parts(nsres))*$parts(nsres)]



More information about the grass-commit mailing list