Просмотр исходного кода

Merge pull request #12425 from german77/temp-fix

service: hid: Fix crash on InitializeVibrationDevice
liamwhite 2 лет назад
Родитель
Сommit
ad7445d4cc
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      src/core/hle/service/hid/hid_server.cpp

+ 1 - 1
src/core/hle/service/hid/hid_server.cpp

@@ -51,7 +51,7 @@ private:
         IPC::RequestParser rp{ctx};
         const auto vibration_device_handle{rp.PopRaw<Core::HID::VibrationDeviceHandle>()};
 
-        if (resource_manager != nullptr) {
+        if (resource_manager != nullptr && resource_manager->GetNpad()) {
             resource_manager->GetNpad()->InitializeVibrationDevice(vibration_device_handle);
         }