diff options
Diffstat (limited to 'common/config-file.cpp')
-rw-r--r-- | common/config-file.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/common/config-file.cpp b/common/config-file.cpp index fe042e9eda..0ce6dcf0c8 100644 --- a/common/config-file.cpp +++ b/common/config-file.cpp @@ -226,6 +226,15 @@ bool ConfigFile::saveToStream(WriteStream &stream) { return !stream.err(); } +void ConfigFile::addSection(const String §ion) { + Section *s = getSection(section); + if (s) + return; + + Section newSection; + newSection.name = section; + _sections.push_back(newSection); +} void ConfigFile::removeSection(const String §ion) { assert(isValidName(section)); |