Nathan Moinvaziri
2c51fa719e
Clang-format style changes.
2024-11-01 16:37:57 -07:00
Yu SuiXian
d1f4d18899
Update comments style in various code files
2023-12-29 07:04:22 -08:00
Thomas Gamper
83301fc2a1
mz_os.h - fix indentation; mz_os_win32.c - adjust for utf8 strings to be represented by char*; test_encoding.cc - remove useless cast
2023-06-08 11:25:14 -07:00
Nathan Moinvaziri
65219949ff
Fixed missing defines on older versions of Windows after bcrypt change.
2023-04-19 09:15:06 -07:00
Nathan Moinvaziri
c9fc27ccee
Use calloc instead of malloc + memset and use strdup where possible.
2023-02-24 14:35:31 -08:00
Nathan Moinvaziri
261041dabc
Remove useless MZ_CUSTOM_ALLOC and MZ_CUSTOM_FREE.
...
It would have required an include to make it useful.
2023-02-24 14:23:04 -08:00
Nathan Moinvaziri
f07faecdde
Remove all comparisons to NULL.
2023-02-19 16:04:13 -08:00
Nathan Moinvaziri
1e4cc21871
Fixed minor formatting whitespace changes.
2023-02-19 10:41:34 -08:00
Nathan Moinvaziri
9829913018
Remove MZ_WINRT_API, use newer API if targeting newer version of Windows
2023-02-17 09:47:02 -08:00
Nathan Moinvaziri
03e4d2213d
Remove copyright years.
2023-02-16 13:14:21 -08:00
Nathan Moinvaziri
848c3e3503
Removed empty lines.
2022-11-29 17:19:49 -08:00
Nathan Moinvaziri
5354bc842c
Added missing include for FSCTL_GET_REPARSE_POINT on Windows. #656
2022-11-29 16:51:25 -08:00
Alnoor Allidina
91c9e269f1
Fix handle leak in low memory situations.
2022-08-06 06:31:51 -07:00
Nathan Moinvaziri
db95894646
Updated name of project to minizip-ng.
2021-01-23 16:19:05 -08:00
ptc-tgamper
01ade0721d
mz_os_win32.c - use memset to zero init, renaming
2020-12-03 08:19:52 -08:00
ptc-tgamper
9b42223635
mz_os_win32.c - fix MZ_WINRT_API compile errors
2020-12-03 08:19:52 -08:00
Nathan Moinvaziri
32dc664898
Fixed GCC compiler warnings on Windows.
2020-06-19 21:33:52 -07:00
Nathan Moinvaziri
70811ac6f5
Remove version number from headers.
2020-06-19 21:21:12 -07:00
Nathan Moinvaziri
dc6962b5fa
Use same brace style as zlib.
2020-06-14 22:00:02 -07:00
Nathan Moinvaziri
16704829e2
Fixed casting warnings when using warning level 4 in MSVC.
2020-06-08 12:35:50 -07:00
Nathan Moinvaziri
2aa369c468
Version 2.9.3.
2020-05-21 07:31:09 -07:00
Nathan Moinvaziri
b39f7a0e89
Version 2.9.2.
2020-02-12 08:38:09 -08:00
David Korth
4d76c8b508
mz_os_win32.c: kernel32.dll is always loaded, so use GetModuleHandleW().
...
The kernel32.dll pathname code had two issues:
1. Using sizeof() for wchar_t[]. sizeof() returns the number of bytes,
but the wcs*() functions need number of characters, so we end up
telling wcsncat() that the buffer is twice as big as it actually is.
2. wcsncat()'s size parameter is supposed to be the *remaining* size
in the buffer, not the total size. wcscat_s() should be used instead,
since it takes the total size of the buffer.
None of this is actually needed, since kernel32.dll is used by all
Windows programs, so it's always loaded in memory.
2020-02-08 22:13:10 -05:00
Nathan Moinvaziri
370ab036f3
Version 2.9.1.
2019-11-15 13:24:17 -08:00
Nathan Moinvaziri
e3c9fe7556
Fixed formatting.
2019-10-19 17:30:54 -07:00
Nathan Moinvaziri
5cc8a54813
Fixed formatting.
2019-10-19 17:30:54 -07:00
Viktor Szakats
6ae07cb4f2
fix Windows-specific compiler error and warnings
...
Exprienced in a mingw-w64 + clang-9 cross-build environment:
```
mz_os_win32.c:560:22: error: use of undeclared identifier 'SYMBOLIC_LINK_FLAG_DIRECTORY'
flags |= SYMBOLIC_LINK_FLAG_DIRECTORY;
^
mz_os_win32.c:632:91: warning: incompatible pointer types passing 'int32_t *' (aka 'int *') to parameter of type 'LPDWORD' (aka 'unsigned long *')
[-Wincompatible-pointer-types]
if (DeviceIoControl(handle, FSCTL_GET_REPARSE_POINT, NULL, 0, buffer, sizeof(buffer), &length, NULL) == TRUE)
^~~~~~~
/usr/local/opt/mingw-w64/toolchain-x86_64/x86_64-w64-mingw32/include/ioapiset.h:22:175: note: passing argument to parameter 'lpBytesReturned' here
WINBASEAPI WINBOOL WINAPI DeviceIoControl (HANDLE hDevice, DWORD dwIoControlCode, LPVOID lpInBuffer, DWORD nInBufferSize, LPVOID lpOutBuffer, DWORD nOutBufferSize, LPDWORD lpBytesReturned, LPOVE...
^
mz_os_win32.c:654:42: warning: passing 'uint8_t *' (aka 'unsigned char *') to parameter of type 'const char *' converts between pointers to integer types with
different sign [-Wpointer-sign]
strncpy(target_path, target_path_utf8, max_target_path - 1);
^~~~~~~~~~~~~~~~
/usr/local/opt/mingw-w64/toolchain-x86_64/x86_64-w64-mingw32/include/string.h:89:69: note: passing argument to parameter '_Source' here
char *strncpy(char * __restrict__ _Dest,const char * __restrict__ _Source,size_t _Count) __MINGW_ATTRIB_DEPRECATED_SEC_WARN;
^
mz_os_win32.c:657:38: warning: passing 'uint8_t *' (aka 'unsigned char *') to parameter of type 'const char *' converts between pointers to integer types with
different sign [-Wpointer-sign]
if (mz_os_is_dir(target_path_utf8) == MZ_OK)
^~~~~~~~~~~~~~~~
mz_os_win32.c:473:34: note: passing argument to parameter 'path' here
int32_t mz_os_is_dir(const char *path)
^
3 warnings and 1 error generated.
```
2019-10-19 17:30:54 -07:00
Nathan Moinvaziri
10ac291d91
Version 2.9.0.
2019-09-18 16:55:43 -07:00
Nathan Moinvaziri
32fd805440
Version 2.8.9.
2019-07-04 10:32:02 -07:00
Nathan Moinvaziri
fbfd4e82f7
Version 2.8.8.
2019-05-22 17:50:39 -07:00
Nathan Moinvaziri
64c4c7f868
Version 2.8.7.
2019-05-09 18:46:18 -07:00
Nathan Moinvaziri
7d94b1ffa1
Fixed symbolic link issues on win32. Ensure that reading a symbolic link dir on windows produces linkname with slash at the end for recreation.
2019-05-08 23:41:47 -07:00
Nathan Moinvaziri
3a941ef473
Return forward slashed path from mz_os_read_symlink on windows.
2019-05-08 19:24:09 -07:00
Nathan Moinvaziri
880be2eaae
Fixed formatting and code cleanup.
2019-05-05 20:30:23 -07:00
Nathan Moinvaziri
6d7160f3d8
Fixed formatting.
2019-05-02 21:11:31 -07:00
Nathan Moinvaziri
3249eac087
Added support for symbolic links. ZipArchive/ZipArchive#424 .
2019-05-02 21:07:39 -07:00
Nathan Moinvaziri
4fe0687243
Version 2.8.6.
2019-04-08 13:26:32 -07:00
Nathan Moinvaziri
488f20ff1b
Version 2.8.5.
2019-03-17 09:38:10 -07:00
Nathan Moinvaziri
e54d842759
Fixed check for drive letter if contains slash.
2019-03-09 20:12:48 -08:00
Nathan Moinvaziri
85cf8563c9
Fixed comment formatting.
2019-03-07 12:37:19 -08:00
Tamas Szarka
a7e69c76be
Allow recursively creating dirs in Windows path
...
Please see issue here:
https://github.com/nmoinvaz/minizip/issues/369
2019-03-07 18:43:52 +01:00
Nathan Moinvaziri
9805ab4117
Version 2.8.4.
2019-02-14 17:16:01 -08:00
Nathan Moinvaziri
2e2f995eda
Version 2.8.3.
2019-01-26 16:49:48 -08:00
Nathan Moinvaziri
2ca7f3950c
Version 2.8.2.
2019-01-08 16:07:10 -08:00
Nathan Moinvaziri
1ff40343b5
Version 2.8.1.
2018-12-01 09:59:19 -08:00
Nathan Moinvaziri
2df1ecbce4
Fixed some code analysis warnings.
2018-12-01 08:59:21 -08:00
Nathan Moinvaziri
5cb88b8f09
Version 2.8.0.
2018-11-24 17:59:11 -08:00
Nathan Moinvaziri
6f3a0a6ad0
Use all win32 api.
2018-11-21 14:53:36 -08:00
Nathan Moinvaziri
1ee609b759
Make inttypes.h optional. #345
2018-11-19 21:34:35 -08:00
Nathan Moinvaziri
b2b082c67d
Version 2.7.5.
2018-11-13 15:22:15 -08:00