Fixed compiler warnings
authorSam Lantinga
Tue, 27 Nov 2012 01:07:44 -0800
changeset 67081fa41febb331
parent 6707 70eeb7e3ec2f
child 6709 3b43d3a9b7d5
Fixed compiler warnings
src/joystick/SDL_gamecontroller.c
test/automated/rwops/rwops.c
     1.1 --- a/src/joystick/SDL_gamecontroller.c	Tue Nov 27 00:58:12 2012 -0800
     1.2 +++ b/src/joystick/SDL_gamecontroller.c	Tue Nov 27 01:07:44 2012 -0800
     1.3 @@ -96,7 +96,9 @@
     1.4  };
     1.5  
     1.6  static ControllerMapping_t *s_pSupportedControllers = NULL;
     1.7 +#ifdef SDL_JOYSTICK_DINPUT
     1.8  static ControllerMapping_t *s_pXInputMapping = NULL;
     1.9 +#endif
    1.10  
    1.11  /* The SDL game controller structure */
    1.12  struct _SDL_GameController
     2.1 --- a/test/automated/rwops/rwops.c	Tue Nov 27 00:58:12 2012 -0800
     2.2 +++ b/test/automated/rwops/rwops.c	Tue Nov 27 01:07:44 2012 -0800
     2.3 @@ -62,13 +62,13 @@
     2.4  static int rwops_testGeneric( SDL_RWops *rw, int write )
     2.5  {
     2.6     char buf[sizeof(hello_world)];
     2.7 -   int i;
     2.8 +   Sint64 i;
     2.9  
    2.10     /* Set to start. */
    2.11     i = SDL_RWseek( rw, 0, RW_SEEK_SET );
    2.12     if (SDL_ATvassert( i == 0,
    2.13              "Seeking with SDL_RWseek (RW_SEEK_SET): got %d, expected %d",
    2.14 -            i, 0 ))
    2.15 +            (int)i, 0 ))
    2.16        return 1;
    2.17  
    2.18     /* Test write. */
    2.19 @@ -86,14 +86,14 @@
    2.20     i = SDL_RWseek( rw, 6, RW_SEEK_SET );
    2.21     if (SDL_ATvassert( i == 6,
    2.22              "Seeking with SDL_RWseek (RW_SEEK_SET): got %d, expected %d",
    2.23 -            i, 0 ))
    2.24 +            (int)i, 0 ))
    2.25         return 1;
    2.26  
    2.27     /* Test seek. */
    2.28     i = SDL_RWseek( rw, 0, RW_SEEK_SET );
    2.29     if (SDL_ATvassert( i == 0,
    2.30              "Seeking with SDL_RWseek (RW_SEEK_SET): got %d, expected %d",
    2.31 -            i, 0 ))
    2.32 +            (int)i, 0 ))
    2.33        return 1;
    2.34  
    2.35     /* Test read. */
    2.36 @@ -108,12 +108,12 @@
    2.37     i = SDL_RWseek( rw, -4, RW_SEEK_CUR );
    2.38     if (SDL_ATvassert( i == sizeof(hello_world)-5,
    2.39              "Seeking with SDL_RWseek (RW_SEEK_CUR): got %d, expected %d",
    2.40 -            i, sizeof(hello_world)-5 ))
    2.41 +            (int)i, sizeof(hello_world)-5 ))
    2.42        return 1;
    2.43     i = SDL_RWseek( rw, -1, RW_SEEK_END );
    2.44     if (SDL_ATvassert( i == sizeof(hello_world)-2,
    2.45              "Seeking with SDL_RWseek (RW_SEEK_END): got %d, expected %d",
    2.46 -            i, sizeof(hello_world)-2 ))
    2.47 +            (int)i, sizeof(hello_world)-2 ))
    2.48        return 1;
    2.49  
    2.50     return 0;