Secure filename copy to fixed size variable wfileName

Tomasz Jezierski - Tefnet developers at tefnet.pl
Mon Apr 21 08:53:24 CDT 2008


---
 dlls/shell32/shlexec.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/dlls/shell32/shlexec.c b/dlls/shell32/shlexec.c
index 794d0bd..a26048a 100644
--- a/dlls/shell32/shlexec.c
+++ b/dlls/shell32/shlexec.c
@@ -1711,10 +1711,10 @@ BOOL SHELL_execute( LPSHELLEXECUTEINFOW sei, SHELL_ExecuteW32 execfunc )
 		}
 	    }
 
-	    strcpyW(wfileName, sei_tmp.lpFile);
+           StrCpyNW(wfileName, sei_tmp.lpFile,sizeof(wfileName));
 	}
     } else
-	strcpyW(wfileName, sei_tmp.lpFile);
+       StrCpyNW(wfileName, sei_tmp.lpFile,sizeof(wfileName));
 
     lpFile = wfileName;
 
-- 
1.5.3.7


--=-vIHPmoYj9qvHpqf+0Adm--




More information about the wine-patches mailing list