From 4fd89b0b8f0b01412f15384acf7fb6af38b4626f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Szymon=20Aceda=C5=84ski?= Date: Sun, 22 Jan 2017 14:15:12 +0100 Subject: [PATCH] Fixed compilation warning on Mac IOHIDManagerRegisterDeviceMatchingCallback must not be called with nullptr as the second argument. --- src/Cockpit/NavDisplay.cxx | 2 +- src/Input/FGMacOSXEventInput.cxx | 3 --- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/src/Cockpit/NavDisplay.cxx b/src/Cockpit/NavDisplay.cxx index d2182eaee..504cf97f5 100644 --- a/src/Cockpit/NavDisplay.cxx +++ b/src/Cockpit/NavDisplay.cxx @@ -183,7 +183,7 @@ private: class SymbolRule { public: - SymbolRule() + SymbolRule() : enabled(false) { } diff --git a/src/Input/FGMacOSXEventInput.cxx b/src/Input/FGMacOSXEventInput.cxx index eaf451108..517322e17 100644 --- a/src/Input/FGMacOSXEventInput.cxx +++ b/src/Input/FGMacOSXEventInput.cxx @@ -229,9 +229,6 @@ void FGMacOSXEventInput::shutdown() { FGEventInput::shutdown(); - IOHIDManagerRegisterDeviceMatchingCallback(d->hidManager, nullptr, nullptr); - IOHIDManagerRegisterDeviceRemovalCallback(d->hidManager, nullptr, nullptr); - IOHIDManagerClose(d->hidManager, kIOHIDOptionsTypeNone); IOHIDManagerUnscheduleFromRunLoop(d->hidManager, CFRunLoopGetCurrent(), kCFRunLoopDefaultMode); CFRelease(d->hidManager);