From eb45ddf6f89cdc25a7619141e4a773bb15af0a71 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Bernon?= Date: Wed, 4 Oct 2023 17:38:54 +0200 Subject: [PATCH] lsteamclient: Add warnings and asserts to unixlib calls. CW-Bug-Id: #22729 --- lsteamclient/unixlib.h | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/lsteamclient/unixlib.h b/lsteamclient/unixlib.h index ced51781..1044f85a 100644 --- a/lsteamclient/unixlib.h +++ b/lsteamclient/unixlib.h @@ -4,6 +4,7 @@ #include #include #include +#include #include #include @@ -206,7 +207,13 @@ struct networking_message #include -#define STEAMCLIENT_CALL( code, args ) WINE_UNIX_CALL( unix_ ## code, args ) +#define STEAMCLIENT_CALL( code, args ) \ + ({ \ + NTSTATUS status = WINE_UNIX_CALL( unix_ ## code, args ); \ + if (status) WARN( #code " failed, status %#x\n", (UINT)status ); \ + assert( !status ); \ + status; \ + }) #ifdef __cplusplus } /* extern "C" */