0
0
mirror of https://github.com/mongodb/mongo.git synced 2024-12-01 09:32:32 +01:00

SERVER-24049: print name of duplicate server parameter

This commit is contained in:
Scott Hernandez 2016-06-17 12:37:42 -04:00 committed by Scott Hernandez
parent 4896d1ffa2
commit bcafb88541

View File

@ -28,11 +28,14 @@
* it in the license file.
*/
#define MONGO_LOG_DEFAULT_COMPONENT ::mongo::logger::LogComponent::kControl
#include "mongo/platform/basic.h"
#include "mongo/base/parse_number.h"
#include "mongo/client/replica_set_monitor.h"
#include "mongo/db/server_parameters.h"
#include "mongo/util/log.h"
namespace mongo {
@ -73,8 +76,10 @@ ServerParameterSet* ServerParameterSet::getGlobal() {
void ServerParameterSet::add(ServerParameter* sp) {
ServerParameter*& x = _map[sp->name()];
if (x)
if (x) {
severe() << "'" << x->name() << "' already exists in the server parameter set.";
abort();
}
x = sp;
}