[GRASS-SVN] r52907 - grass/branches/releasebranch_6_4/vector/v.digit

svn_grass at osgeo.org svn_grass at osgeo.org
Sat Aug 25 07:24:34 PDT 2012


Author: mmetz
Date: 2012-08-25 07:24:34 -0700 (Sat, 25 Aug 2012)
New Revision: 52907

Modified:
   grass/branches/releasebranch_6_4/vector/v.digit/attr.c
   grass/branches/releasebranch_6_4/vector/v.digit/c_face.c
   grass/branches/releasebranch_6_4/vector/v.digit/centre.c
   grass/branches/releasebranch_6_4/vector/v.digit/form.c
   grass/branches/releasebranch_6_4/vector/v.digit/generate.c
   grass/branches/releasebranch_6_4/vector/v.digit/line.c
   grass/branches/releasebranch_6_4/vector/v.digit/main.c
Log:
v.digit: partially revert r46624

Modified: grass/branches/releasebranch_6_4/vector/v.digit/attr.c
===================================================================
--- grass/branches/releasebranch_6_4/vector/v.digit/attr.c	2012-08-25 14:00:52 UTC (rev 52906)
+++ grass/branches/releasebranch_6_4/vector/v.digit/attr.c	2012-08-25 14:24:34 UTC (rev 52907)
@@ -91,7 +91,7 @@
 	    G_debug(2, "Record already existed.");
 	}
 	else if (ret == -1) {
-	    G_warning("%s", _("Cannot create new record."));
+	    G_warning(_("Cannot create new record."));
 	}
     }
 

Modified: grass/branches/releasebranch_6_4/vector/v.digit/c_face.c
===================================================================
--- grass/branches/releasebranch_6_4/vector/v.digit/c_face.c	2012-08-25 14:00:52 UTC (rev 52906)
+++ grass/branches/releasebranch_6_4/vector/v.digit/c_face.c	2012-08-25 14:24:34 UTC (rev 52907)
@@ -279,7 +279,7 @@
     }
 
     if (db_create_index2(driver, Fi->table, argv[3]) != DB_OK) {
-	G_warning("%s", _("Cannot create index"));
+	G_warning(_("Cannot create index"));
 	db_set_string(&err, _("Cannot create index:\n"));
 	db_append_string(&err, db_get_error_msg());
 	db_close_database(driver);

Modified: grass/branches/releasebranch_6_4/vector/v.digit/centre.c
===================================================================
--- grass/branches/releasebranch_6_4/vector/v.digit/centre.c	2012-08-25 14:00:52 UTC (rev 52906)
+++ grass/branches/releasebranch_6_4/vector/v.digit/centre.c	2012-08-25 14:24:34 UTC (rev 52907)
@@ -175,7 +175,7 @@
     Vect_close(&Map);
 
     if (1 == G_put_window(&GRegion))
-	G_message("%s", _("Region restored to original extent."));
+	G_message(_("Region restored to original extent."));
 
     /* clear the screen */
     Tcl_Eval(Toolbox, ".screen.canvas delete all");

Modified: grass/branches/releasebranch_6_4/vector/v.digit/form.c
===================================================================
--- grass/branches/releasebranch_6_4/vector/v.digit/form.c	2012-08-25 14:00:52 UTC (rev 52906)
+++ grass/branches/releasebranch_6_4/vector/v.digit/form.c	2012-08-25 14:24:34 UTC (rev 52907)
@@ -94,7 +94,7 @@
 
     /* Check if all internal values are set */
     if (Drvname == NULL || Dbname == NULL || Tblname == NULL || Key == NULL) {
-	G_warning("%s", _("db connection was not set by form\n"));
+	G_warning(_("db connection was not set by form"));
 	sprintf(buf, "set submit_msg \"db connection was not set by form.\"");
 	Tcl_Eval(interp, buf);
 	Tcl_Eval(interp, "set submit_result 0");
@@ -105,7 +105,7 @@
     G_debug(2, "Open driver");
     driver = db_start_driver(Drvname);
     if (driver == NULL) {
-	G_warning("%s", _("Cannot open driver\n"));
+	G_warning(_("Cannot open driver"));
 	sprintf(buf, "set submit_msg \"Cannot open driver '%s'\"", Drvname);
 	Tcl_Eval(interp, buf);
 	Tcl_Eval(interp, "set submit_result 0");
@@ -117,7 +117,7 @@
     db_set_handle(&handle, Dbname, NULL);
     G_debug(2, "Open database");
     if (db_open_database(driver, &handle) != DB_OK) {
-	G_warning("%s", _("Cannot open database\n"));
+	G_warning(_("Cannot open database"));
 	db_shutdown_driver(driver);
 	sprintf(buf,
 		"set submit_msg \"Cannot open database '%s' by driver '%s'\"",
@@ -130,7 +130,7 @@
 
     db_set_string(&table_name, Tblname);
     if (db_describe_table(driver, &table_name, &table) != DB_OK) {
-	G_warning("%s", _("Cannot describe table\n"));
+	G_warning(_("Cannot describe table"));
 	db_shutdown_driver(driver);
 	db_close_database(driver);
 	sprintf(buf, "set submit_msg \"Cannot describe table '%s'\"",
@@ -159,7 +159,7 @@
 	    }
 	}
 	if (!found && (G_strcasecmp(Columns[i].name, F_ENCODING) != 0)) {
-	    G_warning("%s", _("Cannot find column type"));
+	    G_warning(_("Cannot find column type"));
 	    db_close_database(driver);
 	    db_shutdown_driver(driver);
 	    sprintf(buf, "set submit_msg \"Cannot find column type\"");
@@ -225,7 +225,7 @@
 					buf, 2000, NULL, NULL, NULL);
 
 		if (ret != TCL_OK) {
-		    G_warning("%s", _("Could not convert UTF to external."));
+		    G_warning(_("Could not convert UTF to external."));
 		    db_set_string(&strval, Columns[i].value);
 		}
 		else {
@@ -253,7 +253,7 @@
     db_shutdown_driver(driver);
 
     if (ret != DB_OK) {
-	G_warning("%s", _("Cannot update table"));
+	G_warning(_("Cannot update table"));
 	Tcl_VarEval(interp, "set submit_msg \"Cannot update table:\n",
 		    db_get_error_msg(), "\"", NULL);
 	Tcl_Eval(interp, "set submit_result 0");

Modified: grass/branches/releasebranch_6_4/vector/v.digit/generate.c
===================================================================
--- grass/branches/releasebranch_6_4/vector/v.digit/generate.c	2012-08-25 14:00:52 UTC (rev 52906)
+++ grass/branches/releasebranch_6_4/vector/v.digit/generate.c	2012-08-25 14:24:34 UTC (rev 52907)
@@ -74,7 +74,7 @@
     G_debug(2, "Open driver");
     driver = db_start_driver(drvname);
     if (driver == NULL) {
-	G_warning("%s", _("Cannot open driver"));
+	G_warning(_("Cannot open driver"));
 	sprintf(buf, _("Cannot open driver '%s'<BR>"),
 		escape_tcl_string(drvname));
 	*form = G_store(buf);
@@ -86,7 +86,7 @@
     db_set_handle(&handle, dbname, NULL);
     G_debug(2, "Open database");
     if (db_open_database(driver, &handle) != DB_OK) {
-	G_warning("%s", _("Cannot open database"));
+	G_warning(_("Cannot open database"));
 	db_shutdown_driver(driver);
 	sprintf(buf, _("Cannot open database '%s' by driver '%s'<BR>"),
 		escape_tcl_string(dbname), escape_tcl_string(drvname));
@@ -103,7 +103,7 @@
     G_debug(2, "%s", buf);
     db_set_string(&sql, buf);
     if (db_open_select_cursor(driver, &sql, &cursor, DB_SEQUENTIAL) != DB_OK) {
-	G_warning("%s", _("Cannot open select cursor"));
+	G_warning(_("Cannot open select cursor"));
 	db_close_database(driver);
 	db_shutdown_driver(driver);
 	sprintf(buf,
@@ -118,7 +118,7 @@
     table = db_get_cursor_table(&cursor);
 
     if (db_fetch(&cursor, DB_NEXT, &more) != DB_OK) {
-	G_warning("%s", _("Cannot fetch next record"));
+	G_warning(_("Cannot fetch next record"));
 	db_close_cursor(&cursor);
 	db_close_database(driver);
 	db_shutdown_driver(driver);
@@ -127,7 +127,7 @@
     }
 
     if (!more) {
-	G_warning("%s", _("No database record"));
+	G_warning(_("No database record"));
 	if (format == F_HTML) {
 	    *form = G_store("No record selected.<BR>");
 	}

Modified: grass/branches/releasebranch_6_4/vector/v.digit/line.c
===================================================================
--- grass/branches/releasebranch_6_4/vector/v.digit/line.c	2012-08-25 14:00:52 UTC (rev 52906)
+++ grass/branches/releasebranch_6_4/vector/v.digit/line.c	2012-08-25 14:24:34 UTC (rev 52907)
@@ -188,7 +188,7 @@
 		}
 	    }
 	    if (Vect_append_point(nl->Points, x, y, 0) == -1) {
-		G_warning("%s", _("Out of memory! Point not added."));
+		G_warning(_("Out of memory! Point not added."));
 		return 0;
 	    }
 
@@ -243,7 +243,7 @@
 		updated_lines_and_nodes_erase_refresh_display();
 	    }
 	    else
-		G_warning("%s", _("Less than 2 points for line -> nothing written"));
+		G_warning(_("Less than 2 points for line -> nothing written"));
 
 	    return 1;
 	}

Modified: grass/branches/releasebranch_6_4/vector/v.digit/main.c
===================================================================
--- grass/branches/releasebranch_6_4/vector/v.digit/main.c	2012-08-25 14:00:52 UTC (rev 52906)
+++ grass/branches/releasebranch_6_4/vector/v.digit/main.c	2012-08-25 14:24:34 UTC (rev 52907)
@@ -147,10 +147,10 @@
     mapset = G_find_vector2(map_opt->answer, G_mapset());
     if (mapset == NULL) {
 	if (new_f->answer) {
-	    G_message("%s", _("New empty map created."));
 	    Vect_open_new(&Map, map_opt->answer, 0);
 	    Vect_build(&Map);
 	    Vect_close(&Map);
+	    G_message(_("New empty map created."));
 	    Vect_open_update(&Map, map_opt->answer, G_mapset());
 	}
 	else {



More information about the grass-commit mailing list