From 4e97cc4dbec36f6241a35b1a30881ff2613050a2 Mon Sep 17 00:00:00 2001 From: David Fort Date: Tue, 19 Dec 2023 10:19:37 +0100 Subject: [PATCH] [build] fix build without AINPUT channel If the option was disabled, it was not building. --- client/common/client.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/client/common/client.c b/client/common/client.c index dc43b48e1..734a348f5 100644 --- a/client/common/client.c +++ b/client/common/client.c @@ -2140,6 +2140,10 @@ BOOL freerdp_client_use_relative_mouse_events(rdpClientContext* ccontext) const rdpSettings* settings = ccontext->context.settings; const BOOL useRelative = freerdp_settings_get_bool(settings, FreeRDP_MouseUseRelativeMove); const BOOL haveRelative = freerdp_settings_get_bool(settings, FreeRDP_HasRelativeMouseEvent); - const BOOL ainput = ccontext->ainput != NULL; + BOOL ainput = false; +#if defined(CHANNEL_AINPUT_SERVER) + ainput = ccontext->ainput != NULL; +#endif + return useRelative && (haveRelative || ainput); }