diff options
| author | Ted Ross <tross@apache.org> | 2011-05-17 21:05:49 +0000 |
|---|---|---|
| committer | Ted Ross <tross@apache.org> | 2011-05-17 21:05:49 +0000 |
| commit | 6c19bc243f95fff6754624cbbcf7c73cf0a7a37c (patch) | |
| tree | 1afb4aff5b28149f7e9c2440b9f735464ee4f8e0 /cpp/src/qpid/sys/windows/Shlib.cpp | |
| parent | 0d1d4426a8544cd24b3c88e26087356cabf2c034 (diff) | |
| download | qpid-python-6c19bc243f95fff6754624cbbcf7c73cf0a7a37c.tar.gz | |
QPID-2905 - Misc. code cleanup to allow compilation on a wider set of compilers.
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1104560 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/src/qpid/sys/windows/Shlib.cpp')
| -rw-r--r-- | cpp/src/qpid/sys/windows/Shlib.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/cpp/src/qpid/sys/windows/Shlib.cpp b/cpp/src/qpid/sys/windows/Shlib.cpp index 38027de93f..ba18747eb4 100644 --- a/cpp/src/qpid/sys/windows/Shlib.cpp +++ b/cpp/src/qpid/sys/windows/Shlib.cpp @@ -44,7 +44,8 @@ void Shlib::unload() { } void* Shlib::getSymbol(const char* name) { - void* sym = GetProcAddress(static_cast<HMODULE>(handle), name); + // Double cast avoids warning about casting function pointer to object + void *sym = reinterpret_cast<void*>(reinterpret_cast<intptr_t>(GetProcAddress(static_cast<HMODULE>(handle), name))); if (sym == NULL) throw QPID_WINDOWS_ERROR(GetLastError()); return sym; |
