Update of /cvsroot/pclasses/pclasses2/src/System
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv28447/src/System
Modified Files:
PathFinder.cpp
Log Message:
- Small cleanup, doesnt use Path::absPath() twice now
Index: PathFinder.cpp
===================================================================
RCS file: /cvsroot/pclasses/pclasses2/src/System/PathFinder.cpp,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -d -r1.8 -r1.9
--- PathFinder.cpp 24 May 2005 04:19:49 -0000 1.8
+++ PathFinder.cpp 16 Jun 2005 13:10:44 -0000 1.9
@@ -112,12 +112,15 @@
return emptyStr;
#define CHECKPATH(CHECKAT) \
- P_TRACE(PathFinder) << "testing '" << CHECKAT << "'"; \
- if( ! CHECKAT.empty() && Path(CHECKAT).isAccessible() ) \
{ \
- P_TRACE(PathFinder) << "found '" << CHECKAT << "'"; \
- return _hitcache.insert(std::make_pair(resource, CHECKAT)).first->second; \
- }
+ Path tmpPath(CHECKAT); \
+ P_TRACE(PathFinder) << "testing '" << CHECKAT << "'"; \
+ if( ! CHECKAT.empty() && tmpPath.isAccessible() ) \
+ { \
+ P_TRACE(PathFinder) << "found '" << CHECKAT << "'"; \
+ return _hitcache.insert(std::make_pair(resource, tmpPath.absPath())).first->second; \
+ } \
+ } \
if(check_cache)
{
@@ -143,11 +146,9 @@
while(piter != _paths.end())
{
path = (*piter);
+
if(!path.empty())
- {
- path = Path(path).absPath();
path += Unicode::String::fromAscii(Path::separator());
- }
++piter;
|