From 907722538cf76f8937bf82f1680cdba32bdb282b Mon Sep 17 00:00:00 2001 From: Daniel De Graaf Date: Sun, 7 Mar 2010 19:06:32 -0600 Subject: Change OperInfo to store oper/type/class together. This allows privelages to be granted using or instead of requiring blocks. --- src/configparser.cpp | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'src/configparser.cpp') diff --git a/src/configparser.cpp b/src/configparser.cpp index 587f3f21d..3b4b743ab 100644 --- a/src/configparser.cpp +++ b/src/configparser.cpp @@ -496,9 +496,10 @@ ConfigTag::ConfigTag(const std::string& Tag, const std::string& file, int line) std::string OperInfo::getConfig(const std::string& key) { std::string rv; - if (type_block) - type_block->readString(key, rv); - if (oper_block) - oper_block->readString(key, rv); + for(std::vector >::iterator i = config_blocks.begin(); i != config_blocks.end(); i++) + { + if ((**i).readString(key, rv)) + return rv; + } return rv; } -- cgit v1.3.1-10-gc9f91