Browse Source
Merge pull request #4998 from Morph1984/bioshock-patch
hid: Check if applet_resource exists in InitializeVibrationDevice
pull/15/merge
bunnei
5 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with
4 additions and
2 deletions
-
src/core/hle/service/hid/hid.cpp
|
|
|
@ -157,8 +157,10 @@ private: |
|
|
|
IPC::RequestParser rp{ctx}; |
|
|
|
const auto vibration_device_handle{rp.PopRaw<Controller_NPad::DeviceHandle>()}; |
|
|
|
|
|
|
|
applet_resource->GetController<Controller_NPad>(HidController::NPad) |
|
|
|
.InitializeVibrationDevice(vibration_device_handle); |
|
|
|
if (applet_resource != nullptr) { |
|
|
|
applet_resource->GetController<Controller_NPad>(HidController::NPad) |
|
|
|
.InitializeVibrationDevice(vibration_device_handle); |
|
|
|
} |
|
|
|
|
|
|
|
LOG_DEBUG(Service_HID, "called, npad_type={}, npad_id={}, device_index={}", |
|
|
|
vibration_device_handle.npad_type, vibration_device_handle.npad_id, |
|
|
|
|