* ---------------------------------------------------
*/
-#include "inspircd_config.h"
#include "configreader.h"
-#include <string>
#include <sstream>
-#include <iostream>
#include <fstream>
#include "inspircd.h"
-#include "inspstring.h"
-
-#include "userprocess.h"
#include "xline.h"
std::vector<std::string> old_module_names, new_module_names, added_modules, removed_modules;
*OperOnlyStats = *ModPath = *MyExecutable = *DisabledCommands = *PID = '\0';
log_file = NULL;
NoUserDns = forcedebug = OperSpyWhois = nofork = HideBans = HideSplits = false;
- writelog = AllowHalfop = true;
+ CycleHosts = writelog = AllowHalfop = true;
dns_timeout = DieDelay = 5;
MaxTargets = 20;
NetBufferSize = 10240;
{"options", "tempdir", &this->TempDir, DT_CHARPTR, ValidateTempDir},
{"options", "nouserdns", &this->NoUserDns, DT_BOOLEAN, NoValidation},
{"options", "syntaxhints", &this->SyntaxHints, DT_BOOLEAN, NoValidation},
+ {"options", "cyclehosts", &this->CycleHosts, DT_BOOLEAN, NoValidation},
{"pid", "file", &this->PID, DT_CHARPTR, NoValidation},
{NULL}
};
if (this->LoadConf(newconfig, CONFIG_FILE, errstr))
{
/* If we succeeded, set the ircd config to the new one */
- this->config_data = newconfig;
-
-/* int c = 1;
- std::string last;
-
- for(ConfigDataHash::const_iterator i = this->config_data.begin(); i != this->config_data.end(); i++)
- {
- c = (i->first != last) ? 1 : c+1;
- last = i->first;
-
- std::cout << "[" << i->first << " " << c << "/" << this->config_data.count(i->first) << "]" << std::endl;
-
- for(KeyValList::const_iterator j = i->second.begin(); j != i->second.end(); j++)
- std::cout << "\t" << j->first << " = " << j->second << std::endl;
-
- std::cout << "[/" << i->first << " " << c << "/" << this->config_data.count(i->first) << "]" << std::endl;
- }
- */ }
+ this->config_data = newconfig;
+ }
else
{
ServerInstance->Log(DEFAULT, "There were errors in your configuration:\n%s", errstr.str().c_str());
if (conf.get(real_character))
{
ServerInstance->Log(DEBUG,"Escaping %c", real_character);
+ if (real_character == 'n')
+ real_character = '\n';
line += real_character;
continue;
}
if ((*c == '\\') && (in_quote))
{
c++;
- current_value += *c;
+ if (*c == 'n')
+ current_value += '\n';
+ else
+ current_value += *c;
continue;
}
if (*c == '"')