src/joystick/windows/SDL_dxjoystick.c
changeset 6698 28ab2ef7bfc9
parent 6693 3c98e4ec2180
child 6707 70eeb7e3ec2f
     1.1 --- a/src/joystick/windows/SDL_dxjoystick.c	Mon Nov 26 22:09:58 2012 -0800
     1.2 +++ b/src/joystick/windows/SDL_dxjoystick.c	Mon Nov 26 22:27:49 2012 -0800
     1.3 @@ -707,6 +707,7 @@
     1.4      dipdw.diph.dwHeaderSize = sizeof(DIPROPHEADER);
     1.5  
     1.6      /* allocate memory for system specific hardware data */
     1.7 +	joystick->instance_id = joystickdevice->nInstanceID;
     1.8      joystick->hwdata =
     1.9          (struct joystick_hwdata *) SDL_malloc(sizeof(struct joystick_hwdata));
    1.10      if (joystick->hwdata == NULL) {
    1.11 @@ -716,7 +717,6 @@
    1.12      SDL_memset(joystick->hwdata, 0, sizeof(struct joystick_hwdata));
    1.13      joystick->hwdata->buffered = 1;
    1.14  	joystick->hwdata->removed = 0;
    1.15 -	joystick->instance_id = joystickdevice->nInstanceID;
    1.16      joystick->hwdata->Capabilities.dwSize = sizeof(DIDEVCAPS);
    1.17  	joystick->hwdata->guid = joystickdevice->guid;
    1.18