Fix compilation of <wx/archive.h> on Clang 19 on Fedora

Clang 19.1.0 on Fedora Rawhide fails to compile <wx/archive.h>
because m_rep's members are accessed as if m_rep was not a pointer,
but it is.

This is obviously wrong with any compiler, but apparently because
wxArchiveIterator is a template class, and its operator=() is
never called in tests, its brokenness went unnoticed.
This commit is contained in:
Lauri Nurmi
2024-10-28 12:26:31 +02:00
parent c301af42f9
commit c70a281c33
+2 -2
View File
@@ -217,9 +217,9 @@ public:
wxArchiveIterator& operator =(const wxArchiveIterator& it) {
if (it.m_rep)
it.m_rep.AddRef();
it.m_rep->AddRef();
if (m_rep)
this->m_rep.UnRef();
m_rep->UnRef();
m_rep = it.m_rep;
return *this;
}