]> git.mxchange.org Git - simgear.git/commitdiff
Avoid empty search path extensions for the case that only the bucket index
authorfrohlich <frohlich>
Mon, 25 May 2009 04:59:51 +0000 (04:59 +0000)
committerTim Moore <timoore@redhat.com>
Tue, 2 Jun 2009 22:08:05 +0000 (00:08 +0200)
number is given.

Modified Files:
scene/tgdb/TileEntry.cxx

simgear/scene/tgdb/TileEntry.cxx

index 41f9deddd0fb25311b494d3cd7efb99ee65ddd4d..76416a266369a35714bc2c53a2d717b98d3c1dbb 100644 (file)
@@ -265,7 +265,9 @@ TileEntry::loadTileByFileName(const string& fileName,
 
     osgDB::FilePathList path_list=options->getDatabasePathList();
     // Make sure we find the original filename here...
-    path_list.push_front(osgDB::getFilePath(fileName));
+    std::string filePath = osgDB::getFilePath(fileName);
+    if (!filePath.empty())
+        path_list.push_front(filePath);
 
     // scan and parse all files and store information
     for (unsigned int i = 0; i < path_list.size(); i++) {