wxZipInputStream reading GetExternalAttributes accurately (Issue #26616)

21 views
Skip to first unread message

scottb88

unread,
Jun 20, 2026, 5:40:59 PM (3 days ago) Jun 20
to wx-...@googlegroups.com, Subscribed
scottb88 created an issue (wxWidgets/wxWidgets#26616)

Description

I need to read external attributes.
The bit that distinguishes a symlink from a regular file is always cleared (reads as regular file)

Bug description:

During the execution of wxZipInputStream::GetNextEntry
the value of m_ExternalAttributes of wxZipEntry is read accurately by wxZipEntry::ReadCentral.

But before it returns,
wxZipEntry::SetName is called (master src/common/zipstrm.cpp:1188)
which calls SetIsDir(false) (master include/wx/zipstrm.h:591)
and it clears the symlink bit.

Expected behaviour:

The external attributes returned by wxZipEntry::GetExternalAttributes
accurately reflect the external attributes stored in the zip file.

When printing the external attributes as hexadecimal,
the first digit is '8' for a regular file, and 'A' for a symlink.

Minimal fix: keep symlink bit.
Enhancement: fully support symlinks


Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!
You are receiving this because you are subscribed to this thread.Message ID: <wxWidgets/wxWidgets/issues/26616@github.com>

VZ

unread,
Jun 21, 2026, 10:47:26 AM (3 days ago) Jun 21
to wx-...@googlegroups.com, Subscribed
vadz left a comment (wxWidgets/wxWidgets#26616)

I agree that it would make sense to add some IsSymlink() to wxArchiveEntry, any PRs doing this and implementing support for it in wxZipInputStream would be welcome.


Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!

You are receiving this because you are subscribed to this thread.Message ID: <wxWidgets/wxWidgets/issues/26616/4762328438@github.com>

Reply all
Reply to author
Forward
0 new messages