[mapserver-commits] r12152 - trunk/mapserver/mapcache/src
svn at osgeo.org
svn at osgeo.org
Fri Aug 26 07:02:16 EDT 2011
Author: tbonfort
Date: 2011-08-26 04:02:16 -0700 (Fri, 26 Aug 2011)
New Revision: 12152
Modified:
trunk/mapserver/mapcache/src/cache_disk.c
trunk/mapserver/mapcache/src/http.c
trunk/mapserver/mapcache/src/tileset.c
Log:
dont use echo -n
thomas.bonfort | 2010-11-05 12:22:06 +0100 (Fri, 05 Nov 2010)
Modified: trunk/mapserver/mapcache/src/cache_disk.c
===================================================================
--- trunk/mapserver/mapcache/src/cache_disk.c 2011-08-26 11:02:12 UTC (rev 12151)
+++ trunk/mapserver/mapcache/src/cache_disk.c 2011-08-26 11:02:16 UTC (rev 12152)
@@ -198,7 +198,7 @@
apr_file_t *f;
#ifdef DEBUG
if(tile->lock) {
- r->errmsg = apr_psprintf(r->pool, "### BUG ### waiting for a lock we have created ourself");
+ r->set_error(r,GEOCACHE_DISK_ERROR, "### BUG ### waiting for a lock we have created ourself");
return GEOCACHE_FAILURE;
}
#endif
@@ -276,11 +276,11 @@
#ifdef DEBUG
/* all this should be checked at a higher level */
if(!tile->data || !tile->data->size) {
- r->errmsg = apr_psprintf(r->pool, "attempting to write empty tile to disk");
+ r->set_error(r,GEOCACHE_DISK_ERROR,"attempting to write empty tile to disk");
return GEOCACHE_FAILURE;
}
if(!tile->lock) {
- r->errmsg = apr_psprintf(r->pool, "attempting to write to an unlocked tile");
+ r->set_error(r,GEOCACHE_DISK_ERROR,"attempting to write to an unlocked tile");
return GEOCACHE_FAILURE;
}
#endif
@@ -312,7 +312,7 @@
}
apr_file_close(f);
#ifdef DEBUG
- ap_log_rerror(APLOG_MARK, APLOG_DEBUG, 0, r, "created blank tile %s",blankname);
+ r->log(r,GEOCACHE_DEBUG,"created blank tile %s",blankname);
#endif
}
if(apr_file_link(blankname,filename) != GEOCACHE_SUCCESS) {
@@ -320,7 +320,7 @@
return GEOCACHE_FAILURE; /* we could not create the file */
}
#ifdef DEBUG
- r->errmsg = apr_psprintf(r->pool, "linked blank tile %s to %s",filename,blankname);
+ r->log(r, GEOCACHE_DEBUG, "linked blank tile %s to %s",filename,blankname);
#endif
return GEOCACHE_SUCCESS;
}
Modified: trunk/mapserver/mapcache/src/http.c
===================================================================
--- trunk/mapserver/mapcache/src/http.c 2011-08-26 11:02:12 UTC (rev 12151)
+++ trunk/mapserver/mapcache/src/http.c 2011-08-26 11:02:16 UTC (rev 12152)
@@ -35,7 +35,7 @@
/* specify URL to get */
curl_easy_setopt(curl_handle, CURLOPT_URL, url);
#ifdef DEBUG
- r->log(r, GEOCACHE_LOG_DEBUG, "##### START #####\ncurl requesting url %s",url);
+ r->log(r, GEOCACHE_DEBUG, "##### START #####\ncurl requesting url %s",url);
#endif
/* send all data to this function */
curl_easy_setopt(curl_handle, CURLOPT_WRITEFUNCTION, _geocache_curl_memory_callback);
@@ -60,7 +60,7 @@
/* cleanup curl stuff */
curl_easy_cleanup(curl_handle);
#ifdef DEBUG
- r->log(r, GEOCACHE_LOG_DEBUG, "##### END #####\nrequested url %s",url);
+ r->log(r, GEOCACHE_DEBUG, "##### END #####\nrequested url %s",url);
#endif
return GEOCACHE_SUCCESS;
}
Modified: trunk/mapserver/mapcache/src/tileset.c
===================================================================
--- trunk/mapserver/mapcache/src/tileset.c 2011-08-26 11:02:12 UTC (rev 12151)
+++ trunk/mapserver/mapcache/src/tileset.c 2011-08-26 11:02:16 UTC (rev 12152)
@@ -245,14 +245,14 @@
if(isLocked == GEOCACHE_TRUE) {
/* another thread is rendering the tile, we should wait for it to finish */
#ifdef DEBUG
- r->log(r, GEOCACHE_LOGLEVEL_DEBUG, "cache wait: tileset %s - tile %d %d %d",
+ r->log(r, GEOCACHE_DEBUG, "cache wait: tileset %s - tile %d %d %d",
tile->tileset->name,tile->x, tile->y,tile->z);
#endif
tile->tileset->cache->tile_lock_wait(tile,r);
} else {
/* no other thread is doing the rendering, do it ourselves */
#ifdef DEBUG
- r->log(r, GEOCACHE_LOGLEVEL_DEBUG, "cache miss: tileset %s - tile %d %d %d",
+ r->log(r, GEOCACHE_DEBUG, "cache miss: tileset %s - tile %d %d %d",
tile->tileset->name,tile->x, tile->y,tile->z);
#endif
/* this will query the source to create the tiles, and save them to the cache */
More information about the mapserver-commits
mailing list