Removed variables that current GCC builds warn on as set and never used.
--- a/src/audio/SDL_wave.c Wed Jan 18 03:36:47 2012 -0500
+++ b/src/audio/SDL_wave.c Wed Jan 18 12:17:16 2012 -0500
@@ -47,7 +47,6 @@
static int InitMS_ADPCM(WaveFMT *format)
{
Uint8 *rogue_feel;
- Uint16 extra_info;
int i;
/* Set the rogue pointer to the MS_ADPCM specific data */
@@ -60,7 +59,6 @@
SDL_SwapLE16(format->bitspersample);
rogue_feel = (Uint8 *)format+sizeof(*format);
if ( sizeof(*format) == 16 ) {
- extra_info = ((rogue_feel[1]<<8)|rogue_feel[0]);
rogue_feel += sizeof(Uint16);
}
MS_ADPCM_state.wSamplesPerBlock = ((rogue_feel[1]<<8)|rogue_feel[0]);
@@ -227,7 +225,6 @@
static int InitIMA_ADPCM(WaveFMT *format)
{
Uint8 *rogue_feel;
- Uint16 extra_info;
/* Set the rogue pointer to the IMA_ADPCM specific data */
IMA_ADPCM_state.wavefmt.encoding = SDL_SwapLE16(format->encoding);
@@ -239,7 +236,6 @@
SDL_SwapLE16(format->bitspersample);
rogue_feel = (Uint8 *)format+sizeof(*format);
if ( sizeof(*format) == 16 ) {
- extra_info = ((rogue_feel[1]<<8)|rogue_feel[0]);
rogue_feel += sizeof(Uint16);
}
IMA_ADPCM_state.wSamplesPerBlock = ((rogue_feel[1]<<8)|rogue_feel[0]);
--- a/src/video/SDL_RLEaccel.c Wed Jan 18 03:36:47 2012 -0500
+++ b/src/video/SDL_RLEaccel.c Wed Jan 18 12:17:16 2012 -0500
@@ -1645,9 +1645,8 @@
Uint8 *rlebuf, *dst;
int maxn;
int y;
- Uint8 *srcbuf, *curbuf, *lastline;
+ Uint8 *srcbuf, *lastline;
int maxsize = 0;
- int skip, run;
int bpp = surface->format->BytesPerPixel;
getpix_func getpix;
Uint32 ckey, rgbmask;
@@ -1681,9 +1680,7 @@
/* Set up the conversion */
srcbuf = (Uint8 *)surface->pixels;
- curbuf = srcbuf;
maxn = bpp == 4 ? 65535 : 255;
- skip = run = 0;
dst = rlebuf;
rgbmask = ~surface->format->Amask;
ckey = surface->format->colorkey & rgbmask;
--- a/src/video/SDL_bmp.c Wed Jan 18 03:36:47 2012 -0500
+++ b/src/video/SDL_bmp.c Wed Jan 18 12:17:16 2012 -0500
@@ -132,6 +132,17 @@
biClrUsed = SDL_ReadLE32(src);
biClrImportant = SDL_ReadLE32(src);
}
+
+ /* stop some compiler warnings. */
+ (void) bfSize;
+ (void) bfReserved1;
+ (void) bfReserved2;
+ (void) biPlanes;
+ (void) biSizeImage;
+ (void) biXPelsPerMeter;
+ (void) biYPelsPerMeter;
+ (void) biClrImportant;
+
if (biHeight < 0) {
topDown = SDL_TRUE;
biHeight = -biHeight;
--- a/src/video/SDL_stretch.c Wed Jan 18 03:36:47 2012 -0500
+++ b/src/video/SDL_stretch.c Wed Jan 18 12:17:16 2012 -0500
@@ -205,7 +205,6 @@
int src_locked;
int dst_locked;
int pos, inc;
- int dst_width;
int dst_maxrow;
int src_row, dst_row;
Uint8 *srcp = NULL;
@@ -282,7 +281,6 @@
inc = (srcrect->h << 16) / dstrect->h;
src_row = srcrect->y;
dst_row = dstrect->y;
- dst_width = dstrect->w*bpp;
#ifdef USE_ASM_STRETCH
/* Write the opcodes for this stretch */
--- a/src/video/fbcon/SDL_fb3dfx.c Wed Jan 18 03:36:47 2012 -0500
+++ b/src/video/fbcon/SDL_fb3dfx.c Wed Jan 18 12:17:16 2012 -0500
@@ -96,7 +96,6 @@
SDL_VideoDevice *this = current_video;
int bpp;
Uint32 src_format;
- Uint32 dst_format;
Uint32 src_base;
Uint32 dst_base;
int srcX, srcY;
@@ -118,7 +117,6 @@
src_format = src->pitch | ((bpp+((bpp==8) ? 0 : 8)) << 13);
dst_base = ((char *)dst->pixels - mapped_mem);
bpp = dst->format->BitsPerPixel;
- dst_format = dst->pitch | ((bpp+((bpp==8) ? 0 : 8)) << 13);
srcX = srcrect->x;
srcY = srcrect->y;
--- a/src/video/x11/SDL_x11image.c Wed Jan 18 03:36:47 2012 -0500
+++ b/src/video/x11/SDL_x11image.c Wed Jan 18 12:17:16 2012 -0500
@@ -102,13 +102,11 @@
if(!use_mitshm)
#endif /* not NO_SHARED_MEMORY */
{
- int bpp;
screen->pixels = SDL_malloc(screen->h*screen->pitch);
if ( screen->pixels == NULL ) {
SDL_OutOfMemory();
return -1;
}
- bpp = screen->format->BytesPerPixel;
SDL_Ximage = XCreateImage(SDL_Display, SDL_Visual,
this->hidden->depth, ZPixmap, 0,
(char *)screen->pixels,