Restored user names to file shares

git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@4503 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
drbob 2011-07-31 10:29:50 +00:00
parent 1cb0a9dc21
commit 964f6ccac0

View file

@ -89,13 +89,17 @@ int FileIndexStore::loadCache(const CacheData &data)
// from the cache. Doing this, the file list still shows in a session where we deleted a friend, but will be removed // from the cache. Doing this, the file list still shows in a session where we deleted a friend, but will be removed
// at next restart. // at next restart.
// //
peerState ps;
mPeerMgr->getFriendNetStatus(data.pid, ps);
std::string peername = ps.name + " (" + ps.location + ")";
if (finew->loadIndex(data.path + '/' + data.name, data.hash, data.size)) if (finew->loadIndex(data.path + '/' + data.name, data.hash, data.size))
{ {
#ifdef FIS_DEBUG2 #ifdef FIS_DEBUG2
std::cerr << "FileIndexStore::loadCache() Succeeded!" << std::endl; std::cerr << "FileIndexStore::loadCache() Succeeded!" << std::endl;
#endif #endif
/* set the name */ /* set the name */
finew->root->name = data.pid; // HACK HERE TODO XXX. name; finew->root->name = peername; // data.pid; // HACK HERE TODO XXX. name;
if (local) if (local)
{ {