Browse Source

add some debug messages to help with https://trac.osgeo.org/grass/ticket/1452

git-svn-id: https://svn.osgeo.org/grass/grass/trunk@48391 15284696-431f-4ddb-bdfa-cd5b030d7da7
Hamish Bowman 13 years ago
parent
commit
b3cb757beb
1 changed files with 12 additions and 3 deletions
  1. 12 3
      general/g.proj/datumtrans.c

+ 12 - 3
general/g.proj/datumtrans.c

@@ -62,19 +62,25 @@ int set_datumtrans(int datumtrans, int force)
 	    G_free(defparams);
 	    GPJ_free_datum(&dstruct);
 
+	    G_debug(3, "set_datumtrans(): datum transform terms found "
+		    "with %d options", paramsets);
+
 	    if (status == 1 && paramsets > 1)
 		/* Parameters are missing and there is a choice to be made */
 		force = 1;
 
 	}
-	else
+	else {
 	    /* Datum name not found in table; can't do anything. */
+	    G_debug(3, "set_datumtrans(): Datum name not found in table.");
 	    force = 0;
-
+	}
     }
-    else
+    else {
 	/* No datum name; can't do anything. */
+	G_debug(3, "set_datumtrans(): Datum name either invalid or not supplied.");
 	force = 0;
+    }
 
     if (force) {
 	char *chosenparams = NULL;
@@ -92,6 +98,9 @@ int set_datumtrans(int datumtrans, int force)
 		    ("Invalid transformation number %d; valid range is 1 to %d",
 		     datumtrans, paramsets);
 
+	    G_debug(3, "set_datumtrans(): looking up available datum "
+		    "transforms for <%s>", datum);
+
 	    list = GPJ_get_datum_transform_by_name(datum);
 
 	    if (list != NULL) {