summaryrefslogtreecommitdiffstats
path: root/src/linkedmap.h
diff options
context:
space:
mode:
authorDimitri van Heesch <doxygen@gmail.com>2020-03-30 18:03:16 (GMT)
committerDimitri van Heesch <doxygen@gmail.com>2020-03-30 18:03:16 (GMT)
commit9a04fa4ff9c0ae3421496e96f6c23e0bf2e7db82 (patch)
tree5e073b586b9e3104c7636e67f4e1ff3d44b41783 /src/linkedmap.h
parent339e96085d8a0c9a513d8d5f28a5a9d885f4f1e7 (diff)
downloadDoxygen-9a04fa4ff9c0ae3421496e96f6c23e0bf2e7db82.zip
Doxygen-9a04fa4ff9c0ae3421496e96f6c23e0bf2e7db82.tar.gz
Doxygen-9a04fa4ff9c0ae3421496e96f6c23e0bf2e7db82.tar.bz2
Fixed issue creating std::string from null pointer
Diffstat (limited to 'src/linkedmap.h')
-rw-r--r--src/linkedmap.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/linkedmap.h b/src/linkedmap.h
index 76d906d..3abc069 100644
--- a/src/linkedmap.h
+++ b/src/linkedmap.h
@@ -3,8 +3,8 @@
* Copyright (C) 1997-2020 by Dimitri van Heesch.
*
* Permission to use, copy, modify, and distribute this software and its
- * documentation under the terms of the GNU General Public License is hereby
- * granted. No representations are made about the suitability of this software
+ * documentation under the terms of the GNU General Public License is hereby
+ * granted. No representations are made about the suitability of this software
* for any purpose. It is provided "as is" without express or implied warranty.
* See the GNU General Public License for more details.
*
@@ -58,7 +58,7 @@ class LinkedMap
{
Ptr ptr = std::make_unique<T>(key,std::forward<Args>(args)...);
result = ptr.get();
- m_lookup.insert({std::string(key),result});
+ m_lookup.insert({key ? std::string(key) : std::string(),result});
m_entries.push_back(std::move(ptr));
}
return result;