mirror of
https://git.suyu.dev/suyu/suyu
synced 2024-12-26 03:13:15 -06:00
service: hid: Make sure there's an active aruid handle
This commit is contained in:
parent
b71840bbd2
commit
0b4cc6e14c
1 changed files with 5 additions and 0 deletions
|
@ -870,6 +870,11 @@ void NPad::InitializeVibrationDevice(
|
||||||
const auto aruid = applet_resource_holder.applet_resource->GetActiveAruid();
|
const auto aruid = applet_resource_holder.applet_resource->GetActiveAruid();
|
||||||
const auto npad_index = static_cast<Core::HID::NpadIdType>(vibration_device_handle.npad_id);
|
const auto npad_index = static_cast<Core::HID::NpadIdType>(vibration_device_handle.npad_id);
|
||||||
const auto device_index = static_cast<std::size_t>(vibration_device_handle.device_index);
|
const auto device_index = static_cast<std::size_t>(vibration_device_handle.device_index);
|
||||||
|
|
||||||
|
if (aruid == 0) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
InitializeVibrationDeviceAtIndex(aruid, npad_index, device_index);
|
InitializeVibrationDeviceAtIndex(aruid, npad_index, device_index);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue