Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mumble-voip/mumble.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMikkel Krautz <mikkel@krautz.dk>2016-08-25 00:43:05 +0300
committerGitHub <noreply@github.com>2016-08-25 00:43:05 +0300
commitdd147960e27ff3ee45c261e782f3309d3e568279 (patch)
treed419938702239b80bb1019d4dbd0c5ae719c0ca9 /overlay
parent173aa7df1991cc02808e985e8d6ebc6419bfd243 (diff)
parent4cc34410ddc1fafbbba91977e64e1d653037ce7e (diff)
Merge PR #2525: Fix various warnings in the Windows overlay found by upgrading to MSVC2015
Diffstat (limited to 'overlay')
-rw-r--r--overlay/lib.cpp7
-rw-r--r--overlay/lib.h3
-rw-r--r--overlay/overlay_exe/overlay_exe.cpp4
3 files changed, 11 insertions, 3 deletions
diff --git a/overlay/lib.cpp b/overlay/lib.cpp
index 43613bc98..f1d859846 100644
--- a/overlay/lib.cpp
+++ b/overlay/lib.cpp
@@ -276,7 +276,12 @@ void Pipe::checkMessage(unsigned int width, unsigned int height) {
}
break;
case OVERLAY_MSGTYPE_BLIT: {
- RECT r = {omMsg.omb.x, omMsg.omb.y, omMsg.omb.x + omMsg.omb.w, omMsg.omb.y + omMsg.omb.h};
+ RECT r = {
+ static_cast<LONG>(omMsg.omb.x),
+ static_cast<LONG>(omMsg.omb.y),
+ static_cast<LONG>(omMsg.omb.x + omMsg.omb.w),
+ static_cast<LONG>(omMsg.omb.y + omMsg.omb.h)
+ };
std::vector<RECT>::iterator i = blits.begin();
while (i != blits.end()) {
diff --git a/overlay/lib.h b/overlay/lib.h
index 5cf28fa53..c572f4a5c 100644
--- a/overlay/lib.h
+++ b/overlay/lib.h
@@ -7,6 +7,9 @@
#define MUMBLE_LIB_H_
#define _UNICODE
+#ifdef _WIN32_WINNT
+# undef _WIN32_WINNT
+#endif
#define _WIN32_WINNT 0x0501
#include <stdio.h>
#include <stdarg.h>
diff --git a/overlay/overlay_exe/overlay_exe.cpp b/overlay/overlay_exe/overlay_exe.cpp
index e3e1131a3..4d57801ed 100644
--- a/overlay/overlay_exe/overlay_exe.cpp
+++ b/overlay/overlay_exe/overlay_exe.cpp
@@ -150,8 +150,8 @@ int main(int argc, char **argv) {
}
try {
- unsigned long passedInHandle = std::stoul(handleStr);
- parent = reinterpret_cast<HANDLE>(passedInHandle & 0xFFFFFFFFUL);
+ unsigned long long passedInHandle = std::stoull(handleStr);
+ parent = reinterpret_cast<HANDLE>(passedInHandle & 0xFFFFFFFFULL);
} catch(std::exception &) {
return OVERLAY_HELPER_ERROR_EXE_INVALID_HANDLE_ARGUMENT;
}