another patch for win32 joysticks
authorBrian Paul <brian.paul@tungstengraphics.com>
Tue, 27 Jun 2000 13:39:55 +0000 (13:39 +0000)
committerBrian Paul <brian.paul@tungstengraphics.com>
Tue, 27 Jun 2000 13:39:55 +0000 (13:39 +0000)
src/glut/glx/glut_input.c

index 007883d6b6e25557d4f0fc3253f84846e270af6f..bc93d5e515156e06e7c9ab5d1bed8ccc7b479fa7 100644 (file)
@@ -266,6 +266,10 @@ __glutProcessDeviceEvents(XEvent * event)
     JOYINFOEX info;
     JOYCAPS joyCaps;
 
+    memset(&info, 0, sizeof(JOYINFOEX)); 
+    info.dwSize = sizeof(JOYINFOEX); 
+    info.dwFlags = JOY_RETURNALL;
+
     if (joyGetPosEx(JOYSTICKID1,&info) != JOYERR_NOERROR) {
       __glutHasJoystick = 1;
       joyGetDevCaps(JOYSTICKID1, &joyCaps, sizeof(joyCaps));