From 4b9b8547e687a583ba1261f5d9361f77c86a856d Mon Sep 17 00:00:00 2001 From: Zhiyi Zhang Date: Wed, 2 Jan 2019 21:31:53 +0800 Subject: [PATCH] steamclient: Fix possible crash. Fix a regression caused by a8968fe. https://github.com/ValveSoftware/Proton/issues/2131 Signed-off-by: Zhiyi Zhang --- lsteamclient/steamclient_main.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lsteamclient/steamclient_main.c b/lsteamclient/steamclient_main.c index c6898e58..344473a5 100644 --- a/lsteamclient/steamclient_main.c +++ b/lsteamclient/steamclient_main.c @@ -40,6 +40,9 @@ unsigned int steamclient_unix_path_to_dos_path(bool api_result, const char *src, WCHAR *dosW; uint32 r; + if(!dst || !dst_bytes) + return 0; + if(!src || !api_result){ *dst = 0; return 0;