diff options
author | Jose <jose@zeroc.com> | 2013-01-16 22:12:21 +0100 |
---|---|---|
committer | Jose <jose@zeroc.com> | 2013-01-16 22:12:21 +0100 |
commit | 08ac1ea1ad4ee07a81da1c793cef43b75b9108be (patch) | |
tree | 9c524070990f06ff339057b41348864afed2eccd /cpp/src/Ice/DynamicLibrary.cpp | |
parent | Fixed missing case for ignoring redefinitions (diff) | |
download | ice-08ac1ea1ad4ee07a81da1c793cef43b75b9108be.tar.bz2 ice-08ac1ea1ad4ee07a81da1c793cef43b75b9108be.tar.xz ice-08ac1ea1ad4ee07a81da1c793cef43b75b9108be.zip |
Fixed (ICE-5186) - DynamicLibrary loadEntryPoint problem
Diffstat (limited to 'cpp/src/Ice/DynamicLibrary.cpp')
-rw-r--r-- | cpp/src/Ice/DynamicLibrary.cpp | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/cpp/src/Ice/DynamicLibrary.cpp b/cpp/src/Ice/DynamicLibrary.cpp index 1b7c34e99cc..b573a7f4388 100644 --- a/cpp/src/Ice/DynamicLibrary.cpp +++ b/cpp/src/Ice/DynamicLibrary.cpp @@ -50,13 +50,6 @@ IceInternal::DynamicLibrary::~DynamicLibrary() IceInternal::DynamicLibrary::symbol_type IceInternal::DynamicLibrary::loadEntryPoint(const string& entryPoint, bool useIceVersion) { - -#ifdef _WIN32 - bool isFilePath = entryPoint.find('\\') != string::npos || entryPoint.find('/') != string::npos; -#else - bool isFilePath = entryPoint.find('/') != string::npos; -#endif - string::size_type colon = entryPoint.rfind(':'); #ifdef _WIN32 @@ -84,12 +77,18 @@ IceInternal::DynamicLibrary::loadEntryPoint(const string& entryPoint, bool useIc string funcName = entryPoint.substr(colon + 1); string libPath, libName, version, debug; +#ifdef _WIN32 + bool isFilePath = libSpec.find('\\') != string::npos || entryPoint.find('/') != string::npos; +#else + bool isFilePath = libSpec.find('/') != string::npos; +#endif + if(isFilePath) { #ifdef _WIN32 - string::size_type separator = entryPoint.find_last_of("/\\"); + string::size_type separator = libSpec.find_last_of("/\\"); #else - string::size_type separator = entryPoint.rfind('/'); + string::size_type separator = libSpec.rfind('/'); #endif libPath = libSpec.substr(0, separator + 1); libSpec = libSpec.substr(separator + 1); |