Skip to content

Commit

Permalink
Fixed uninitialized variable in FreeBSD joystick.
Browse files Browse the repository at this point in the history
Patch by Marcus von Appen.
  • Loading branch information
icculus committed Feb 5, 2010
1 parent 6b14861 commit ef5d66d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/joystick/bsd/SDL_sysjoystick.c
Expand Up @@ -303,11 +303,11 @@ SDL_SYS_JoystickOpen(SDL_Joystick *joy)
strerror(errno));
goto usberr;
}
rep = &hw->inreport;
#if defined(__FREEBSD__) && (__FreeBSD_kernel_version > 800063)
rep->rid = hid_get_report_id(fd);
if (rep->rid < 0) {
#else
rep = &hw->inreport;
if (ioctl(fd, USB_GET_REPORT_ID, &rep->rid) < 0) {
#endif
rep->rid = -1; /* XXX */
Expand Down

0 comments on commit ef5d66d

Please sign in to comment.