From: Mark Jansen Date: Sat, 4 Mar 2017 20:29:46 +0000 (+0000) Subject: [APPHELP] Fix a possible read past the buffer in SdbpIsPathOnRemovableMedia. X-Git-Tag: ReactOS-0.4.4-CLT2017~29 X-Git-Url: https://git.reactos.org/?p=reactos.git;a=commitdiff_plain;h=0adcb4d02a55a7e82d4ccfcd4492447f7f94d4f5 [APPHELP] Fix a possible read past the buffer in SdbpIsPathOnRemovableMedia. svn path=/trunk/; revision=74062 --- diff --git a/reactos/dll/appcompat/apphelp/layer.c b/reactos/dll/appcompat/apphelp/layer.c index ab15b2fce31..afe1ca3d5a0 100644 --- a/reactos/dll/appcompat/apphelp/layer.c +++ b/reactos/dll/appcompat/apphelp/layer.c @@ -109,7 +109,7 @@ BOOL SdbpIsPathOnRemovableMedia(PCWSTR Path) { WCHAR tmp[] = { 'A',':','\\',0 }; ULONG type; - if (!Path) + if (!Path || Path[0] == UNICODE_NULL) { SHIM_ERR("Invalid argument\n"); return FALSE;