Skip to content
Permalink
Browse files

Merge PR #2525: Fix various warnings in the Windows overlay found by …

…upgrading to MSVC2015
  • Loading branch information...
mkrautz committed Aug 24, 2016
2 parents 173aa7d + 4cc3441 commit dd147960e27ff3ee45c261e782f3309d3e568279
Showing with 11 additions and 3 deletions.
  1. +6 −1 overlay/lib.cpp
  2. +3 −0 overlay/lib.h
  3. +2 −2 overlay/overlay_exe/overlay_exe.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()) {
@@ -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>
@@ -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;
}

0 comments on commit dd14796

Please sign in to comment.
You can’t perform that action at this time.