mirror of
https://github.com/owasp-modsecurity/ModSecurity.git
synced 2025-10-06 22:36:51 +03:00
Merge pull request #39 from gwroblew/remotes/trunk
Fixed OWASP CRS files overwriting in installer.
This commit is contained in:
@@ -4132,6 +4132,8 @@ ZRESULT TUnzip::Unzip(int index,void *dst,unsigned int len,DWORD flags)
|
|||||||
TCHAR dstfull[MAX_PATH];
|
TCHAR dstfull[MAX_PATH];
|
||||||
_tcscpy(dstfull, rootdir);
|
_tcscpy(dstfull, rootdir);
|
||||||
_tcscat(dstfull, (const TCHAR *)dst);
|
_tcscat(dstfull, (const TCHAR *)dst);
|
||||||
|
SetFileAttributes( dstfull, GetFileAttributes(dstfull) & ~FILE_ATTRIBUTE_READONLY);
|
||||||
|
::DeleteFile(dstfull);
|
||||||
h = ::CreateFile(dstfull, GENERIC_WRITE, 0, NULL, CREATE_ALWAYS,
|
h = ::CreateFile(dstfull, GENERIC_WRITE, 0, NULL, CREATE_ALWAYS,
|
||||||
ze.attr, NULL);
|
ze.attr, NULL);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user