fixed double / in path that would cause plugin loading issue on windows

git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@5572 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
csoler 2012-09-19 21:24:12 +00:00
parent 5016236030
commit 481e263c20

View File

@ -140,7 +140,10 @@ void RsPluginManager::loadPlugins(const std::vector<std::string>& plugin_directo
{
std::string fname;
dirIt.d_name(fname);
std::string fullname = plugin_directories[i] + "/" + fname;
char lc = plugin_directories[i][plugin_directories[i].length()-1] ; // length cannot be 0 here.
std::string fullname = (lc == '/' || lc == '\\')? (plugin_directories[i] + fname) : (plugin_directories[i] + "/" + fname) ;
if(!acceptablePluginName(fullname))
continue ;