use real name instead hash name for partials for preview; hope to work now

git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@1400 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
alexandrut 2009-07-21 21:37:51 +00:00
parent 369bb6a5c5
commit e7b42238cb

View File

@ -735,16 +735,7 @@ bool ftController::FileRequest(std::string fname, std::string hash,
{ RsStackMutex stack(ctrlMutex); /******* LOCKED ********/ { RsStackMutex stack(ctrlMutex); /******* LOCKED ********/
/* extension added to partial name to made savepath = mPartialsPath + "/" + fname;
* possible preview of partial files from gui */
std::string ext = "";
int pos = fname.find_last_of('.');
if (pos > 0) /* don't apply for hidden files with no extension */
{
ext = fname.substr(pos);
}
savepath = mPartialsPath + "/" + hash + ext;
destination = dest + "/" + fname; destination = dest + "/" + fname;
/* if no destpath - send to download directory */ /* if no destpath - send to download directory */