[mapserver-commits] r10520 - trunk/mapserver

svn at osgeo.org svn at osgeo.org
Mon Sep 27 13:30:51 EDT 2010


Author: warmerdam
Date: 2010-09-27 17:30:51 +0000 (Mon, 27 Sep 2010)
New Revision: 10520

Modified:
   trunk/mapserver/mapdrawgdal.c
   trunk/mapserver/maprasterquery.c
Log:
correct order of arguments to msSetError()

Modified: trunk/mapserver/mapdrawgdal.c
===================================================================
--- trunk/mapserver/mapdrawgdal.c	2010-09-24 20:56:14 UTC (rev 10519)
+++ trunk/mapserver/mapdrawgdal.c	2010-09-27 17:30:51 UTC (rev 10520)
@@ -886,7 +886,7 @@
             if( eErr != CE_None ) 
             { 
                 msSetError( MS_IOERR, "GDALRasterIO() failed: %s",  
-                            CPLGetLastErrorMsg(), "drawGDAL()" ); 
+                            "drawGDAL()", CPLGetLastErrorMsg() ); 
                 free( pabyRaw1 ); 
                 return -1; 
             } 
@@ -1488,8 +1488,7 @@
         {
             msSetError(MS_IOERR, 
                        "Failed to open LUT file '%s'.",
-                       path,
-                       "drawGDAL()");
+                       "drawGDAL()", path );
             return -1;
         }
         
@@ -1500,8 +1499,8 @@
         {
             msSetError(MS_IOERR, 
                        "LUT definition from file %s longer than maximum buffer size (%d bytes).",
-                       path, sizeof(lut_def_fromfile),
-                       "drawGDAL()");
+                       "drawGDAL()", 
+                       path, sizeof(lut_def_fromfile) );
             return -1;
         }
         
@@ -1600,8 +1599,10 @@
 
         if( eErr != CE_None )
 	{
-            msSetError( MS_IOERR, "GDALDatasetRasterIO() failed: %s", 
-                        CPLGetLastErrorMsg(), "drawGDAL()" );
+            msSetError( MS_IOERR, 
+                        "GDALDatasetRasterIO() failed: %s", 
+                        "drawGDAL()",
+                        CPLGetLastErrorMsg() );
 	    return -1;
 	}
 
@@ -1657,7 +1658,8 @@
     if( eErr != CE_None )
     {
         msSetError( MS_IOERR, "GDALDatasetRasterIO() failed: %s", 
-                    CPLGetLastErrorMsg(), "drawGDAL()" );
+                    "drawGDAL()",
+                    CPLGetLastErrorMsg() );
         
         free( pafWholeRawData );
         return -1;
@@ -1700,8 +1702,8 @@
                 free( pafWholeRawData );
 		msSetError( MS_MISCERR, 
 			    "SCALE PROCESSING option unparsable for layer %s.",
-			    layer->name, 
-			    "msDrawGDAL()" );
+                            "msDrawGDAL()",
+			    layer->name );
 		return -1;
             }
 	    else
@@ -2235,8 +2237,7 @@
     if( eErr != CE_None )
     {
         msSetError( MS_IOERR, "GDALRasterIO() failed: %s", 
-                    CPLGetLastErrorMsg(), 
-                    "msDrawRasterLayerGDAL_RawMode()" );
+                    "msDrawRasterLayerGDAL_RawMode()", CPLGetLastErrorMsg() );
         free( pBuffer );
         free( f_nodatas );
         return -1;
@@ -2422,8 +2423,8 @@
             free( pafRawData );
             msSetError( MS_MISCERR, 
                         "SCALE PROCESSING option unparsable for layer %s.",
-                        layer->name, 
-                        "msDrawGDAL()" );
+                        "msDrawGDAL()",
+                        layer->name );
             return -1;
         }
         else
@@ -2482,8 +2483,8 @@
             free( pafRawData );
             msSetError( MS_MISCERR, 
                         "SCALE_BUCKETS PROCESSING option is not a value of 2 or more: %s.",
-                        pszBuckets, 
-                        "msDrawRasterLayerGDAL_16BitClassification()" );
+                        "msDrawRasterLayerGDAL_16BitClassification()",
+                        pszBuckets );
             return -1;
         }
     }

Modified: trunk/mapserver/maprasterquery.c
===================================================================
--- trunk/mapserver/maprasterquery.c	2010-09-24 20:56:14 UTC (rev 10519)
+++ trunk/mapserver/maprasterquery.c	2010-09-27 17:30:51 UTC (rev 10520)
@@ -550,8 +550,7 @@
     if( eErr != CE_None )
     {
         msSetError( MS_IOERR, "GDALDatasetRasterIO() failed: %s", 
-                    CPLGetLastErrorMsg(), 
-                    "msRasterQueryByRectLow()" );
+                    "msRasterQueryByRectLow()", CPLGetLastErrorMsg() );
 
         free( pafRaster );
         return -1;
@@ -922,8 +921,9 @@
               if( layer->debug || map->debug )
                 msSetError( MS_IMGERR, 
                             "Unable to open file %s for layer %s ... fatal error.\n%s", 
+                            "msRasterQueryByRect()",
                             szPath, layer->name, cpl_error_msg,
-                            "msRasterQueryByRect()" );
+                             );
               return(MS_FAILURE);
             }
             if( ignore_missing == MS_MISSING_DATA_LOG ) {



More information about the mapserver-commits mailing list