]> git.saurik.com Git - wxWidgets.git/blobdiff - src/common/dynlib.cpp
fixed memory leak in colour parsing code
[wxWidgets.git] / src / common / dynlib.cpp
index 2c82172f8fffa9b8d0ed46a34868eca6bc4daa71..f90788fb174e606f10a00193dd7e598f1ae26ec4 100644 (file)
@@ -363,8 +363,7 @@ wxLibrary *wxLibraries::LoadLibrary(const wxString& name)
     if (node != NULL)
         return ((wxLibrary *)node->Data());
 #else // !OS/2
-       node = m_loaded.Find(name.GetData());
-    if ( node )
+    if ( (node = m_loaded.Find(name.GetData())) != NULL)
         return ((wxLibrary *)node->Data());
 #endif
     // If DLL shares data, this is necessary.