Skip to content

Commit c881cff

Browse files
committed
Improved check for global plugins vs local plugins to use full pathnames
1 parent bf9c23b commit c881cff

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

doc.cpp

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -827,6 +827,7 @@ void CMUSHclientDoc::SetUpOutputWindow (void)
827827
for (vector<string>::const_iterator i = v.begin (); i != v.end (); i++)
828828
{
829829
strPath = i->c_str ();
830+
string sGlobalPluginPath (Make_Absolute_Path (strPath));
830831
bool bAlreadyLoaded = false;
831832

832833
// see if we already have this one
@@ -835,8 +836,10 @@ void CMUSHclientDoc::SetUpOutputWindow (void)
835836
++pit)
836837
{
837838
CPlugin * p = *pit;
839+
// convert filename to absolute path for a better comparison
840+
string sThisPluginPath (Make_Absolute_Path (p->m_strSource));
838841

839-
if (p->m_strSource == strPath)
842+
if (sGlobalPluginPath == sThisPluginPath)
840843
{
841844
bAlreadyLoaded = true;
842845
p->m_bGlobal = true;
@@ -853,8 +856,10 @@ void CMUSHclientDoc::SetUpOutputWindow (void)
853856
++pit)
854857
{
855858
CPlugin * p = *pit;
859+
// convert filename to absolute path for a better comparison
860+
string sThisPluginPath (Make_Absolute_Path (p->m_strSource));
856861

857-
if (p->m_strSource == strPath)
862+
if (sGlobalPluginPath == sThisPluginPath)
858863
{
859864
p->m_bGlobal = true;
860865
break;

0 commit comments

Comments
 (0)