https://git.reactos.org/?p=reactos.git;a=commitdiff;h=53badbd2f78630fc0cc72e3cd3ff0e6a04a00eab

commit 53badbd2f78630fc0cc72e3cd3ff0e6a04a00eab
Author:     Mark Jansen <[email protected]>
AuthorDate: Sun Sep 6 14:28:56 2020 +0200
Commit:     Mark Jansen <[email protected]>
CommitDate: Sun Sep 6 14:28:56 2020 +0200

    [ZIPFLDR] Fix PathCompactPathW writing out of bounds
    CORE-17245
---
 dll/shellext/zipfldr/CZipExtract.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/dll/shellext/zipfldr/CZipExtract.cpp 
b/dll/shellext/zipfldr/CZipExtract.cpp
index f9dd21d9b0e..1ccba19b226 100644
--- a/dll/shellext/zipfldr/CZipExtract.cpp
+++ b/dll/shellext/zipfldr/CZipExtract.cpp
@@ -293,7 +293,7 @@ public:
         {
             SetWizardButtons(PSWIZB_FINISH);
             CStringW Path = m_pExtract->m_Directory;
-            PWSTR Ptr = Path.GetBuffer();
+            PWSTR Ptr = Path.GetBuffer(MAX_PATH);
             RECT rc;
             ::GetWindowRect(GetDlgItem(IDC_DESTDIR), &rc);
             HDC dc = GetDC();

Reply via email to