[GRASS-SVN] r46109 - grass/trunk/lib/python

svn_grass at osgeo.org svn_grass at osgeo.org
Tue Apr 26 11:33:30 EDT 2011


Author: glynn
Date: 2011-04-26 08:33:30 -0700 (Tue, 26 Apr 2011)
New Revision: 46109

Modified:
   grass/trunk/lib/python/core.py
Log:
Improve handling of flags= argument


Modified: grass/trunk/lib/python/core.py
===================================================================
--- grass/trunk/lib/python/core.py	2011-04-26 15:12:27 UTC (rev 46108)
+++ grass/trunk/lib/python/core.py	2011-04-26 15:33:30 UTC (rev 46109)
@@ -120,6 +120,8 @@
     if verbose:
 	args.append("--v")
     if flags:
+        if '-' in flags:
+            raise ScriptError("'-' is not a valid flag")
 	args.append("-%s" % flags)
     for opt, val in options.iteritems():
 	if val != None:



More information about the grass-commit mailing list