diff --git a/src/kits/device/Joystick.cpp b/src/kits/device/Joystick.cpp index 88d60cc6f4..dd39996741 100644 --- a/src/kits/device/Joystick.cpp +++ b/src/kits/device/Joystick.cpp @@ -62,10 +62,8 @@ BJoystick::BJoystick() BJoystick::~BJoystick() { - if (ffd >= 0) { + if (ffd >= 0) close(ffd); - ffd = -1; - } for (int32 count = fDevices->CountItems() - 1; count >= 0; count--) { free(fDevices->RemoveItem(count));