[GRASS-SVN] r49509 - grass/branches/develbranch_6/lib/gis

svn_grass at osgeo.org svn_grass at osgeo.org
Sat Dec 3 16:19:10 EST 2011


Author: neteler
Date: 2011-12-03 13:19:10 -0800 (Sat, 03 Dec 2011)
New Revision: 49509

Modified:
   grass/branches/develbranch_6/lib/gis/parser.c
Log:
Don't silently ignore invalid arguments, raise an error (backport from trunk, r49481)

Modified: grass/branches/develbranch_6/lib/gis/parser.c
===================================================================
--- grass/branches/develbranch_6/lib/gis/parser.c	2011-12-03 19:04:39 UTC (rev 49508)
+++ grass/branches/develbranch_6/lib/gis/parser.c	2011-12-03 21:19:10 UTC (rev 49509)
@@ -64,14 +64,14 @@
  *    that the "map" option is required and also that the number 12 is
  *    out of range.  The acceptable range (or list) will be printed.
  *
- * (C) 2001-2009 by the GRASS Development Team
+ * (C) 2001-2009, 2011 by the GRASS Development Team
  *
  * This program is free software under the GNU General Public License
  * (>=v2). Read the file COPYING that comes with GRASS for details.
  *
  * \author Original author CERL; enhancements: Radim Blazek
  *
- * \date 2003-2009
+ * \date 2003-2011
  *
  */
 
@@ -966,7 +966,7 @@
 	    }
 
 	    /* If we see the non valid argument (no "=", just argument) */
-	    else if (contains(ptr, '=') == 0) {
+	    else {
 		fprintf(stderr, _("Sorry <%s> is not a valid option\n"), ptr);
 		error = 1;
 	    }



More information about the grass-commit mailing list