mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-06-20 12:24:24 -04:00
corrected disabled RequestdirDetails in FileIndexStore to be able to retrieve root directory of a user ID
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@4683 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
107f64c23f
commit
379927a846
1 changed files with 6 additions and 5 deletions
|
@ -161,7 +161,7 @@ int FileIndexStore::loadCache(const CacheData &data)
|
||||||
|
|
||||||
|
|
||||||
/* Search Interface - For Directory Access */
|
/* Search Interface - For Directory Access */
|
||||||
int FileIndexStore::RequestDirDetails(std::string uid, std::string /*path*/, DirDetails &/*details*/) const
|
int FileIndexStore::RequestDirDetails(std::string uid, std::string /*path*/, DirDetails& details) const
|
||||||
{
|
{
|
||||||
/* lock it up */
|
/* lock it up */
|
||||||
lockData();
|
lockData();
|
||||||
|
@ -169,17 +169,18 @@ int FileIndexStore::RequestDirDetails(std::string uid, std::string /*path*/, Dir
|
||||||
std::map<RsPeerId, FileIndex *>::const_iterator it;
|
std::map<RsPeerId, FileIndex *>::const_iterator it;
|
||||||
it = indices.find(uid);
|
it = indices.find(uid);
|
||||||
bool found = true;
|
bool found = true;
|
||||||
if (it == indices.end())
|
|
||||||
|
if (it != indices.end())
|
||||||
{
|
{
|
||||||
//DirEntry *fdir = (it->second).lookupDirectory(path);
|
//DirEntry *fdir = (it->second).lookupDirectory(path);
|
||||||
/* translate it
|
/* translate it
|
||||||
*/
|
*/
|
||||||
found = false;
|
bool b = FileIndex::extractData((it->second)->root,details) ;
|
||||||
|
|
||||||
|
found = found && b ;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
|
||||||
found = false;
|
found = false;
|
||||||
}
|
|
||||||
|
|
||||||
unlockData();
|
unlockData();
|
||||||
return found;
|
return found;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue