From e78744554e01a08283e27d81e7aee2436e67eaaf Mon Sep 17 00:00:00 2001 From: Ingo Weinhold Date: Wed, 22 Jul 2009 01:10:45 +0000 Subject: [PATCH] Domain::_LocateDirectory(): We first want to check whether the directory exists before trying to map its parent. This is what _LocateEntry() already does, so things can be simplified. Should fix problems with finding local source files for good. Or so I hope. :-) git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31683 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- src/apps/debugger/files/FileManager.cpp | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/src/apps/debugger/files/FileManager.cpp b/src/apps/debugger/files/FileManager.cpp index cae6d5564f..8630cf2b2d 100644 --- a/src/apps/debugger/files/FileManager.cpp +++ b/src/apps/debugger/files/FileManager.cpp @@ -199,17 +199,10 @@ private: return false; } - // locate the parent, if possible, otherwise this directory - BString locatedDirectory; - BString locatedName; - _SplitNormalizedPath(locatedPath, locatedDirectory, locatedName); - if (locatedName != directory->Name()) + if (!_LocateEntry(directory, locatedPath, true, true)) return false; - if (_LocateDirectory(directory->Parent(), locatedDirectory)) { - directory->SetLocatedPath(locatedPath, true); - _LocateEntries(directory, locatedPath); - } + _LocateEntries(directory, locatedPath); return true; }