WGI: Fix a couple of reference leaks

This commit is contained in:
Cameron Gutman 2022-08-28 17:38:02 -05:00
parent 0db1813049
commit b7c1fbf9f0
1 changed files with 3 additions and 0 deletions

View File

@ -560,9 +560,12 @@ WGI_JoystickInit(void)
hr = __FIVectorView_1_Windows__CGaming__CInput__CRawGameController_GetAt(controllers, i, &controller); hr = __FIVectorView_1_Windows__CGaming__CInput__CRawGameController_GetAt(controllers, i, &controller);
if (SUCCEEDED(hr) && controller) { if (SUCCEEDED(hr) && controller) {
IEventHandler_CRawGameControllerVtbl_InvokeAdded(&controller_added, NULL, controller); IEventHandler_CRawGameControllerVtbl_InvokeAdded(&controller_added, NULL, controller);
__x_ABI_CWindows_CGaming_CInput_CIRawGameController_Release(controller);
} }
} }
} }
__FIVectorView_1_Windows__CGaming__CInput__CRawGameController_Release(controllers);
} }
} }