From 754c82d047b80c30ff2f775d32e8b9b054049ebd Mon Sep 17 00:00:00 2001 From: Sadie Powell Date: Tue, 30 Nov 2021 10:54:10 +0000 Subject: Remove undefined behaviour around checking if this is null. --- include/config.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'include') diff --git a/include/config.h b/include/config.h index d8ef07695..82c1ad5c8 100644 --- a/include/config.h +++ b/include/config.h @@ -60,7 +60,7 @@ namespace Configuration } bool Set(const Anope::string &tag, const Anope::string &value); - const item_map* GetItems() const; + const item_map &GetItems() const; }; template<> CoreExport const Anope::string Block::Get(const Anope::string &tag, const Anope::string& def) const; @@ -129,6 +129,9 @@ namespace Configuration std::map modules; Anope::map bots; + /* Represents a missing tag. */ + Block EmptyBlock; + Conf(); ~Conf(); -- cgit