Skip to content
This repository has been archived by the owner on Feb 11, 2021. It is now read-only.

Commit

Permalink
Fixed variable scoping for Windows build
Browse files Browse the repository at this point in the history
  • Loading branch information
slouken committed Jul 27, 2013
1 parent e9a028d commit 481b4d6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/video/windows/SDL_windowswindow.c
Expand Up @@ -291,7 +291,7 @@ WIN_SetWindowIcon(_THIS, SDL_Window * window, SDL_Surface * icon)
HWND hwnd = ((SDL_WindowData *) window->driverdata)->hwnd;
HICON hicon = NULL;
BYTE *icon_bmp;
int icon_len;
int icon_len, y;
SDL_RWops *dst;

/* Create temporary bitmap buffer */
Expand All @@ -318,7 +318,7 @@ WIN_SetWindowIcon(_THIS, SDL_Window * window, SDL_Surface * icon)

/* Write the pixels upside down into the bitmap buffer */
SDL_assert(icon->format->format == SDL_PIXELFORMAT_ARGB8888);
int y = icon->h;
y = icon->h;
while (y--) {
Uint8 *src = (Uint8 *) icon->pixels + y * icon->pitch;
SDL_RWwrite(dst, src, icon->pitch, 1);
Expand Down

0 comments on commit 481b4d6

Please sign in to comment.