1.1 --- a/src/joystick/darwin/SDL_sysjoystick.c Tue Feb 21 18:29:39 2006 +0000
1.2 +++ b/src/joystick/darwin/SDL_sysjoystick.c Tue Feb 21 19:24:09 2006 +0000
1.3 @@ -585,15 +585,15 @@
1.4 int SDL_SYS_JoystickInit(void)
1.5 {
1.6 IOReturn result = kIOReturnSuccess;
1.7 - mach_port_t masterPort = NULL;
1.8 - io_iterator_t hidObjectIterator = NULL;
1.9 + mach_port_t masterPort = 0;
1.10 + io_iterator_t hidObjectIterator = 0;
1.11 CFMutableDictionaryRef hidMatchDictionary = NULL;
1.12 recDevice *device, *lastDevice;
1.13 - io_object_t ioHIDDeviceObject = NULL;
1.14 + io_object_t ioHIDDeviceObject = 0;
1.15
1.16 SDL_numjoysticks = 0;
1.17
1.18 - if (NULL != gpDeviceList)
1.19 + if (!gpDeviceList)
1.20 {
1.21 SDL_SetError("Joystick: Device list already inited.");
1.22 return -1;
1.23 @@ -608,7 +608,7 @@
1.24
1.25 /* Set up a matching dictionary to search I/O Registry by class name for all HID class devices. */
1.26 hidMatchDictionary = IOServiceMatching (kIOHIDDeviceKey);
1.27 - if ((hidMatchDictionary != NULL))
1.28 + if (hidMatchDictionary)
1.29 {
1.30 /* Add key for device type (joystick, in this case) to refine the matching dictionary. */
1.31
1.32 @@ -637,7 +637,7 @@
1.33 SDL_SetError("Joystick: Couldn't create a HID object iterator.");
1.34 return -1;
1.35 }
1.36 - if (NULL == hidObjectIterator) /* there are no joysticks */
1.37 + if (!hidObjectIterator) /* there are no joysticks */
1.38 {
1.39 gpDeviceList = NULL;
1.40 SDL_numjoysticks = 0;