From dc67dbe5bd5a48756c591ad02b9f68fbd2a57687 Mon Sep 17 00:00:00 2001
From: Dimitri van Heesch <doxygen@gmail.com>
Date: Sun, 19 Jan 2020 20:31:52 +0100
Subject: [PATCH] issue #7474: [1.8.16 regression] HTML output varies from ASLR

---
 src/memberlist.cpp | 11 +++++++++--
 1 file changed, 9 insertions(+), 2 deletions(-)

diff --git a/src/memberlist.cpp b/src/memberlist.cpp
index 278023b..edd164b 100644
--- a/src/memberlist.cpp
+++ b/src/memberlist.cpp
@@ -75,8 +75,15 @@ int MemberList::compareValues(const MemberDef *c1, const MemberDef *c2) const
       return 1;
   }
   int cmp = qstricmp(c1->name(),c2->name());
-  if (cmp==0) cmp = qstricmp(c1->argsString(),c2->argsString());
-  return cmp!=0 ? cmp : c1->getDefLine()-c2->getDefLine();
+  if (cmp==0 && c1->argsString() && c2->argsString())
+  {
+    cmp = qstricmp(c1->argsString(),c2->argsString());
+  }
+  if (cmp==0)
+  {
+    cmp = c1->getDefLine()-c2->getDefLine();
+  }
+  return cmp;
 }
 
 int MemberList::countInheritableMembers(const ClassDef *inheritedFrom) const
-- 
1.8.3.1

