Fixed some OpenWatcom warnings
authorSam Lantinga <slouken@libsdl.org>
Sun, 26 Feb 2006 19:37:40 +0000
changeset 14439ebbbb4ae53b
parent 1442 e3242177fe4a
child 1444 12113661052d
Fixed some OpenWatcom warnings
src/thread/os2/SDL_systhread.c
src/video/SDL_blit_A.c
src/video/SDL_blit_N.c
     1.1 --- a/src/thread/os2/SDL_systhread.c	Sun Feb 26 19:30:21 2006 +0000
     1.2 +++ b/src/thread/os2/SDL_systhread.c	Sun Feb 26 19:37:40 2006 +0000
     1.3 @@ -72,7 +72,7 @@
     1.4    pThreadParms->args = args;
     1.5    // Start the thread using the runtime library of calling app!
     1.6    thread->threadid = thread->handle = (*pfnBeginThread)(threadfunc, NULL, 512*1024, pThreadParms);
     1.7 -  if (thread->threadid<=0)
     1.8 +  if ((int)thread->threadid <= 0)
     1.9    {
    1.10      SDL_SetError("Not enough resources to create thread");
    1.11      return(-1);
     2.1 --- a/src/video/SDL_blit_A.c	Sun Feb 26 19:30:21 2006 +0000
     2.2 +++ b/src/video/SDL_blit_A.c	Sun Feb 26 19:37:40 2006 +0000
     2.3 @@ -1468,10 +1468,11 @@
     2.4  				Uint32 sw, dw, s;
     2.5  				sw = *(Uint32 *)srcp;
     2.6  				dw = *(Uint32 *)dstp;
     2.7 -				if(SDL_BYTEORDER == SDL_BIG_ENDIAN)
     2.8 -					s = (prev_sw << 16) + (sw >> 16);
     2.9 -				else
    2.10 -					s = (prev_sw >> 16) + (sw << 16);
    2.11 +#if SDL_BYTEORDER == SDL_BIG_ENDIAN
    2.12 +				s = (prev_sw << 16) + (sw >> 16);
    2.13 +#else
    2.14 +				s = (prev_sw >> 16) + (sw << 16);
    2.15 +#endif
    2.16  				prev_sw = sw;
    2.17  				*(Uint32 *)dstp = BLEND2x16_50(dw, s, mask);
    2.18  				dstp += 2;
    2.19 @@ -1482,10 +1483,11 @@
    2.20  			/* final pixel if any */
    2.21  			if(w) {
    2.22  				Uint16 d = *dstp, s;
    2.23 -				if(SDL_BYTEORDER == SDL_BIG_ENDIAN)
    2.24 -					s = (Uint16)prev_sw;
    2.25 -				else
    2.26 -					s = (Uint16)(prev_sw >> 16);
    2.27 +#if SDL_BYTEORDER == SDL_BIG_ENDIAN
    2.28 +				s = (Uint16)prev_sw;
    2.29 +#else
    2.30 +				s = (Uint16)(prev_sw >> 16);
    2.31 +#endif
    2.32  				*dstp = BLEND16_50(d, s, mask);
    2.33  				srcp++;
    2.34  				dstp++;
     3.1 --- a/src/video/SDL_blit_N.c	Sun Feb 26 19:30:21 2006 +0000
     3.2 +++ b/src/video/SDL_blit_N.c	Sun Feb 26 19:37:40 2006 +0000
     3.3 @@ -835,10 +835,10 @@
     3.4  #endif
     3.5  
     3.6  /* This is now endian dependent */
     3.7 -#if ( SDL_BYTEORDER == SDL_LIL_ENDIAN )
     3.8 +#if SDL_BYTEORDER == SDL_LIL_ENDIAN
     3.9  #define HI	1
    3.10  #define LO	0
    3.11 -#else /* ( SDL_BYTEORDER == SDL_BIG_ENDIAN ) */
    3.12 +#else /* SDL_BYTEORDER == SDL_BIG_ENDIAN */
    3.13  #define HI	0
    3.14  #define LO	1
    3.15  #endif