From d6a8b7fbc79aab7c04ccfe8afe98b1f0eab00abc Mon Sep 17 00:00:00 2001 From: Sam Lantinga Date: Mon, 11 Feb 2013 21:47:13 -0800 Subject: [PATCH] tree 5b46fd5b8c94 parent 971b278f0756 author Edward Rudd 1358022907 18000 committer Edward Rudd 1358022907 18000 revision 6819 branch default Remove some redundant assigns --- src/events/SDL_touch.c | 1 - src/haptic/darwin/SDL_syshaptic.c | 1 - src/video/SDL_blit_A.c | 2 +- src/video/SDL_shape.c | 1 - 4 files changed, 1 insertion(+), 4 deletions(-) diff --git a/src/events/SDL_touch.c b/src/events/SDL_touch.c index 88a8d4746..2bdcd5571 100644 --- a/src/events/SDL_touch.c +++ b/src/events/SDL_touch.c @@ -125,7 +125,6 @@ SDL_AddTouch(const SDL_Touch * touch, char *name) SDL_memcpy(SDL_touchPads[index], touch, sizeof(*touch)); /* we're setting the touch properties */ - length = 0; length = SDL_strlen(name); SDL_touchPads[index]->focus = 0; SDL_touchPads[index]->name = SDL_malloc((length + 2) * sizeof(char)); diff --git a/src/haptic/darwin/SDL_syshaptic.c b/src/haptic/darwin/SDL_syshaptic.c index feb4309e7..99c807c88 100644 --- a/src/haptic/darwin/SDL_syshaptic.c +++ b/src/haptic/darwin/SDL_syshaptic.c @@ -173,7 +173,6 @@ SDL_SYS_HapticInit(void) /* IOServiceGetMatchingServices consumes dictionary. */ if (!IOIteratorIsValid(iter)) { /* No iterator. */ - numhaptics = 0; return 0; } diff --git a/src/video/SDL_blit_A.c b/src/video/SDL_blit_A.c index d8537ee74..146a8976e 100644 --- a/src/video/SDL_blit_A.c +++ b/src/video/SDL_blit_A.c @@ -258,7 +258,7 @@ static void BlitRGBtoRGBSurfaceAlphaMMX(SDL_BlitInfo * info) { SDL_PixelFormat *df = info->dst_fmt; - Uint32 chanmask = df->Rmask | df->Gmask | df->Bmask; + Uint32 chanmask; unsigned alpha = info->a; if (alpha == 128 && (df->Rmask | df->Gmask | df->Bmask) == 0x00FFFFFF) { diff --git a/src/video/SDL_shape.c b/src/video/SDL_shape.c index 1a807258f..9f74a9bb2 100644 --- a/src/video/SDL_shape.c +++ b/src/video/SDL_shape.c @@ -71,7 +71,6 @@ SDL_CalculateShapeBitmap(SDL_WindowShapeMode mode,SDL_Surface *shape,Uint8* bitm SDL_Color key; if(SDL_MUSTLOCK(shape)) SDL_LockSurface(shape); - pixel = (Uint8*)shape->pixels; for(y = 0;yh;y++) { for(x=0;xw;x++) { alpha = 0;