From d9601ab28527aa443c356415ec10597cf7f28b43 Mon Sep 17 00:00:00 2001 From: Thomas Klausner Date: Wed, 21 Aug 2024 16:13:37 +0200 Subject: [PATCH] Add comment for REPARSE_POINT --- lib/zip_source_file_win32_named.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/zip_source_file_win32_named.c b/lib/zip_source_file_win32_named.c index 39e4a6d7f..a7a1a90c9 100644 --- a/lib/zip_source_file_win32_named.c +++ b/lib/zip_source_file_win32_named.c @@ -224,6 +224,8 @@ _zip_win32_named_op_stat(zip_source_file_context_t *ctx, zip_source_file_stat_t if ((file_attributes.dwFileAttributes & (FILE_ATTRIBUTE_DIRECTORY | FILE_ATTRIBUTE_DEVICE)) == 0) { if (file_attributes.dwFileAttributes & FILE_ATTRIBUTE_REPARSE_POINT) { WIN32_FIND_DATA find_data; + /* Deduplication on Windows replaces files with reparse points; + * accept them as regular files. */ if (file_ops->find_first_file(ctx->fname, &find_data) != INVALID_HANDLE_VALUE) { st->regular_file = (find_data.dwReserved0 == IO_REPARSE_TAG_DEDUP); }