Skip to content

Commit 01bc887

Browse files
committed
issue doxygen#12057 SIGSEGV in \relates resolution when referencing a nested struct and the parent class has a using-alias in another namespace
1 parent 3cec2c4 commit 01bc887

File tree

1 file changed

+9
-3
lines changed

1 file changed

+9
-3
lines changed

src/classdef.cpp

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -955,9 +955,12 @@ std::unique_ptr<ClassDef> ClassDefImpl::deepCopy(const QCString &name) const
955955
auto newMd = md->deepCopy();
956956
if (newMd)
957957
{
958+
AUTO_TRACE_ADD("Copying member {}",newMd->name());
958959
auto mmd = toMemberDefMutable(newMd.get());
959-
AUTO_TRACE_ADD("Copying member {}",mmd->name());
960-
mmd->moveTo(result.get());
960+
if (mmd)
961+
{
962+
mmd->moveTo(result.get());
963+
}
961964

962965
result->internalInsertMember(newMd.get(),newMd->protection(),true);
963966

@@ -4154,7 +4157,10 @@ void ClassDefImpl::mergeCategory(ClassDef *cat)
41544157
{
41554158
auto mmd = toMemberDefMutable(newMd.get());
41564159
AUTO_TRACE_ADD("Copying member {}",mmd->name());
4157-
mmd->moveTo(this);
4160+
if (mmd)
4161+
{
4162+
mmd->moveTo(this);
4163+
}
41584164

41594165
auto newMi=std::make_unique<MemberInfo>(newMd.get(),prot,mi->virt(),mi->inherited(),mi->virtualBaseClass());
41604166
newMi->setScopePath(mi->scopePath());

0 commit comments

Comments
 (0)