Mac and Linux SDL2 binary snapshots
Edward Rudd
2020-05-02 03f8528315fa46c95991a34f3325d7b33ae5538c
source/src/video/windows/SDL_windowsmouse.c
@@ -1,6 +1,6 @@
/*
  Simple DirectMedia Layer
  Copyright (C) 1997-2018 Sam Lantinga <slouken@libsdl.org>
  Copyright (C) 1997-2020 Sam Lantinga <slouken@libsdl.org>
  This software is provided 'as-is', without any express or implied
  warranty.  In no event will the authors be held liable for any damages
@@ -97,6 +97,7 @@
    LPVOID pixels;
    LPVOID maskbits;
    size_t maskbitslen;
    SDL_bool isstack;
    ICONINFO ii;
    SDL_zero(bmh);
@@ -112,7 +113,7 @@
    bmh.bV4BlueMask  = 0x000000FF;
    maskbitslen = ((surface->w + (pad - (surface->w % pad))) / 8) * surface->h;
    maskbits = SDL_stack_alloc(Uint8,maskbitslen);
    maskbits = SDL_small_alloc(Uint8, maskbitslen, &isstack);
    if (maskbits == NULL) {
        SDL_OutOfMemory();
        return NULL;
@@ -129,7 +130,7 @@
    ii.hbmColor = CreateDIBSection(hdc, (BITMAPINFO*)&bmh, DIB_RGB_COLORS, &pixels, NULL, 0);
    ii.hbmMask = CreateBitmap(surface->w, surface->h, 1, 1, maskbits);
    ReleaseDC(NULL, hdc);
    SDL_stack_free(maskbits);
    SDL_small_free(maskbits, isstack);
    SDL_assert(surface->format->format == SDL_PIXELFORMAT_ARGB8888);
    SDL_assert(surface->pitch == surface->w * 4);