[compiler,gcc] fix function pointer casts

use dedicated macro WINPR_FUNC_PTR_CAST to cast function pointers
without warnings.
This commit is contained in:
Armin Novak
2026-03-03 17:23:32 +01:00
parent 782c3d3069
commit 4b4368fc19
3 changed files with 35 additions and 38 deletions

View File

@@ -851,8 +851,8 @@ BOOL freerdp_client_channel_register(rdpChannels* channels, HANDLE handle,
if (!channels || (handle == INVALID_HANDLE_VALUE) || !fkt)
{
WLog_ERR(TAG, "Invalid function arguments (channels=%p, handle=%p, fkt=%p, userdata=%p",
WINPR_CXX_COMPAT_CAST(const void*, channels), handle,
WINPR_CXX_COMPAT_CAST(const void*, fkt), userdata);
WINPR_FUNC_PTR_CAST(channels, const void*), handle,
WINPR_FUNC_PTR_CAST(fkt, const void*), userdata);
return FALSE;
}