mirror of
https://github.com/wiiu-env/libnotifications.git
synced 2024-11-22 03:19:24 +01:00
Fix error handling if FindExport fails
This commit is contained in:
parent
38e02d706a
commit
71e6149b30
@ -105,27 +105,27 @@ NotificationModuleStatus NotificationModule_InitLibrary() {
|
|||||||
}
|
}
|
||||||
if (OSDynLoad_FindExport(sModuleHandle, OS_DYNLOAD_EXPORT_FUNC, "NMAddDynamicNotification", (void **) &sNMAddDynamicNotification) != OS_DYNLOAD_OK) {
|
if (OSDynLoad_FindExport(sModuleHandle, OS_DYNLOAD_EXPORT_FUNC, "NMAddDynamicNotification", (void **) &sNMAddDynamicNotification) != OS_DYNLOAD_OK) {
|
||||||
DEBUG_FUNCTION_LINE_ERR("FindExport NMAddDynamicNotification failed.");
|
DEBUG_FUNCTION_LINE_ERR("FindExport NMAddDynamicNotification failed.");
|
||||||
sNMAddStaticNotification = nullptr;
|
sNMAddDynamicNotification = nullptr;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (OSDynLoad_FindExport(sModuleHandle, OS_DYNLOAD_EXPORT_FUNC, "NMUpdateDynamicNotificationText", (void **) &sNMUpdateDynamicNotificationText) != OS_DYNLOAD_OK) {
|
if (OSDynLoad_FindExport(sModuleHandle, OS_DYNLOAD_EXPORT_FUNC, "NMUpdateDynamicNotificationText", (void **) &sNMUpdateDynamicNotificationText) != OS_DYNLOAD_OK) {
|
||||||
DEBUG_FUNCTION_LINE_ERR("FindExport NMUpdateDynamicNotificationText failed.");
|
DEBUG_FUNCTION_LINE_ERR("FindExport NMUpdateDynamicNotificationText failed.");
|
||||||
sNMAddStaticNotification = nullptr;
|
sNMUpdateDynamicNotificationText = nullptr;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (OSDynLoad_FindExport(sModuleHandle, OS_DYNLOAD_EXPORT_FUNC, "NMUpdateDynamicNotificationBackgroundColor", (void **) &sNMUpdateDynamicNotificationBackgroundColor) != OS_DYNLOAD_OK) {
|
if (OSDynLoad_FindExport(sModuleHandle, OS_DYNLOAD_EXPORT_FUNC, "NMUpdateDynamicNotificationBackgroundColor", (void **) &sNMUpdateDynamicNotificationBackgroundColor) != OS_DYNLOAD_OK) {
|
||||||
DEBUG_FUNCTION_LINE_ERR("FindExport NMUpdateDynamicNotificationBackgroundColor failed.");
|
DEBUG_FUNCTION_LINE_ERR("FindExport NMUpdateDynamicNotificationBackgroundColor failed.");
|
||||||
sNMAddStaticNotification = nullptr;
|
sNMUpdateDynamicNotificationBackgroundColor = nullptr;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (OSDynLoad_FindExport(sModuleHandle, OS_DYNLOAD_EXPORT_FUNC, "NMUpdateDynamicNotificationTextColor", (void **) &sNMUpdateDynamicNotificationTextColor) != OS_DYNLOAD_OK) {
|
if (OSDynLoad_FindExport(sModuleHandle, OS_DYNLOAD_EXPORT_FUNC, "NMUpdateDynamicNotificationTextColor", (void **) &sNMUpdateDynamicNotificationTextColor) != OS_DYNLOAD_OK) {
|
||||||
DEBUG_FUNCTION_LINE_ERR("FindExport NMUpdateDynamicNotificationTextColor failed.");
|
DEBUG_FUNCTION_LINE_ERR("FindExport NMUpdateDynamicNotificationTextColor failed.");
|
||||||
sNMAddStaticNotification = nullptr;
|
sNMUpdateDynamicNotificationTextColor = nullptr;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (OSDynLoad_FindExport(sModuleHandle, OS_DYNLOAD_EXPORT_FUNC, "NMFinishDynamicNotification", (void **) &sNMFinishDynamicNotification) != OS_DYNLOAD_OK) {
|
if (OSDynLoad_FindExport(sModuleHandle, OS_DYNLOAD_EXPORT_FUNC, "NMFinishDynamicNotification", (void **) &sNMFinishDynamicNotification) != OS_DYNLOAD_OK) {
|
||||||
DEBUG_FUNCTION_LINE_ERR("FindExport NMFinishDynamicNotification failed.");
|
DEBUG_FUNCTION_LINE_ERR("FindExport NMFinishDynamicNotification failed.");
|
||||||
sNMAddStaticNotification = nullptr;
|
sNMFinishDynamicNotification = nullptr;
|
||||||
}
|
}
|
||||||
|
|
||||||
sDefaultValues.clear();
|
sDefaultValues.clear();
|
||||||
|
Loading…
Reference in New Issue
Block a user