]> git.mxchange.org Git - simgear.git/blobdiff - simgear/scene/tgdb/TileCache.cxx
Remove using std:: from the metar header, remove HTTP support, add very basic unit...
[simgear.git] / simgear / scene / tgdb / TileCache.cxx
index 5028d1973a6122f59e88dbea70ea1993be83fffd..04ef996f282a3b026ebb0115eea9d68cf9e0449c 100644 (file)
@@ -192,13 +192,8 @@ void TileCache::refresh_tile(long tile_index)
 
     SG_LOG( SG_TERRAIN, SG_DEBUG, "REFRESHING CACHE ENTRY = " << tile_index );
 
-    TileEntry* e = NULL;
-    if (!it->second->is_expired(current_time))
-        e = new TileEntry(it->second);
-
-    entry_free(tile_index);
-    if (e)
-        tile_cache[tile_index] = e;
+    if (it->second)
+        it->second->refresh();
 }
 
 // update tile's priority and expiry time according to current request
@@ -207,7 +202,7 @@ void TileCache::request_tile(TileEntry* t,float priority,bool current_view,doubl
     if ((!current_view)&&(request_time<=0.0))
         return;
 
-    // update priority when hire - or old has expired
+    // update priority when higher - or old request has expired
     if ((t->is_expired(current_time))||
          (priority > t->get_priority()))
     {