summaryrefslogtreecommitdiff
path: root/ndb/src/mgmsrv
diff options
context:
space:
mode:
authorunknown <tomas@poseidon.ndb.mysql.com>2004-10-20 13:42:41 +0000
committerunknown <tomas@poseidon.ndb.mysql.com>2004-10-20 13:42:41 +0000
commite4a86f3237783b356eb448952ae11c292c12006c (patch)
treebd85bda937436c38cfeb5846ed1cad5d2371195d /ndb/src/mgmsrv
parent2da1cbd97dd566d629115f02321ab36aac069ce4 (diff)
downloadmariadb-git-e4a86f3237783b356eb448952ae11c292c12006c.tar.gz
compile warning fixes
mysql-test/ndb/ndbcluster.sh: corrected shell test syntax
Diffstat (limited to 'ndb/src/mgmsrv')
-rw-r--r--ndb/src/mgmsrv/CommandInterpreter.cpp1
-rw-r--r--ndb/src/mgmsrv/Config.cpp3
-rw-r--r--ndb/src/mgmsrv/ConfigInfo.cpp2
-rw-r--r--ndb/src/mgmsrv/InitConfigFileParser.cpp4
-rw-r--r--ndb/src/mgmsrv/Services.cpp10
5 files changed, 13 insertions, 7 deletions
diff --git a/ndb/src/mgmsrv/CommandInterpreter.cpp b/ndb/src/mgmsrv/CommandInterpreter.cpp
index 2c2aeda21ed..2a054a01f1e 100644
--- a/ndb/src/mgmsrv/CommandInterpreter.cpp
+++ b/ndb/src/mgmsrv/CommandInterpreter.cpp
@@ -647,6 +647,7 @@ versionCallback(int nodeId, int version, void * anyData, int errCode){
}
break;
case NDB_MGM_NODE_TYPE_UNKNOWN:
+ case NDB_MGM_NODE_TYPE_REP:
abort();
};
diff --git a/ndb/src/mgmsrv/Config.cpp b/ndb/src/mgmsrv/Config.cpp
index b8a494cb759..f9c6a23f909 100644
--- a/ndb/src/mgmsrv/Config.cpp
+++ b/ndb/src/mgmsrv/Config.cpp
@@ -85,6 +85,9 @@ Config::printAllNameValuePairs(NdbOut &out,
MGM_REQUIRE(prop->get(n, &str_value));
out << str_value;
break;
+ case ConfigInfo::SECTION:
+ out << "SECTION";
+ break;
}
out << endl;
}
diff --git a/ndb/src/mgmsrv/ConfigInfo.cpp b/ndb/src/mgmsrv/ConfigInfo.cpp
index bff7f9be0e6..22338b1a801 100644
--- a/ndb/src/mgmsrv/ConfigInfo.cpp
+++ b/ndb/src/mgmsrv/ConfigInfo.cpp
@@ -3559,7 +3559,7 @@ check_node_vs_replicas(Vector<ConfigInfo::ConfigRuleSection>&sections,
{
unsigned c= 0;
p_db_hosts.get(str.c_str(),&c);
- if (c+1 == (1 << (replicas-1))) // all nodes on same machine
+ if (c+1 == (1u << (replicas-1))) // all nodes on same machine
node_group_warning.append(".\n Host failure will "
"cause complete cluster shutdown.");
else if (c > 0)
diff --git a/ndb/src/mgmsrv/InitConfigFileParser.cpp b/ndb/src/mgmsrv/InitConfigFileParser.cpp
index 652e0f96190..008a9d0551f 100644
--- a/ndb/src/mgmsrv/InitConfigFileParser.cpp
+++ b/ndb/src/mgmsrv/InitConfigFileParser.cpp
@@ -42,7 +42,7 @@ InitConfigFileParser::~InitConfigFileParser() {
// Read Config File
//****************************************************************************
InitConfigFileParser::Context::Context(const ConfigInfo * info)
- : m_configValues(1000, 20), m_userProperties(true) {
+ : m_userProperties(true), m_configValues(1000, 20) {
m_config = new Properties(true);
m_defaults = new Properties(true);
@@ -349,6 +349,8 @@ InitConfigFileParser::storeNameValuePair(Context& ctx,
case ConfigInfo::STRING:
MGM_REQUIRE(ctx.m_currentSection->put(pname, value));
break;
+ case ConfigInfo::SECTION:
+ abort();
}
return true;
}
diff --git a/ndb/src/mgmsrv/Services.cpp b/ndb/src/mgmsrv/Services.cpp
index 5242237a638..9c32facef3e 100644
--- a/ndb/src/mgmsrv/Services.cpp
+++ b/ndb/src/mgmsrv/Services.cpp
@@ -1252,8 +1252,9 @@ MgmStatService::log(int eventType, const Uint32* theData, NodeId nodeId){
Uint32 threshold = 0;
LogLevel::EventCategory cat;
-
- for(unsigned i = 0; i<EventLogger::matrixSize; i++){
+ int i;
+
+ for(i = 0; (unsigned)i<EventLogger::matrixSize; i++){
if(EventLogger::matrix[i].eventType == eventType){
cat = EventLogger::matrix[i].eventCategory;
threshold = EventLogger::matrix[i].threshold;
@@ -1266,7 +1267,6 @@ MgmStatService::log(int eventType, const Uint32* theData, NodeId nodeId){
Vector<NDB_SOCKET_TYPE> copy;
m_clients.lock();
- int i;
for(i = m_clients.size() - 1; i >= 0; i--){
if(threshold <= m_clients[i].m_logLevel.getLogLevel(cat)){
if(m_clients[i].m_socket >= 0 &&
@@ -1279,14 +1279,14 @@ MgmStatService::log(int eventType, const Uint32* theData, NodeId nodeId){
}
m_clients.unlock();
- for(i = 0; (unsigned)i<copy.size(); i++){
+ for(i = 0; (unsigned)i < copy.size(); i++){
NDB_CLOSE_SOCKET(copy[i]);
}
if(copy.size()){
LogLevel tmp; tmp.clear();
m_clients.lock();
- for(i = 0; i < m_clients.size(); i++){
+ for(i = 0; (unsigned)i < m_clients.size(); i++){
tmp.set_max(m_clients[i].m_logLevel);
}
m_clients.unlock();