remove compiler warnings

parent 50ff14b9
...@@ -237,6 +237,7 @@ set_ulimit(const BaseString & pair){ ...@@ -237,6 +237,7 @@ set_ulimit(const BaseString & pair){
} else if(list[0] == "t"){ } else if(list[0] == "t"){
_RLIMIT_FIX(RLIMIT_CPU); _RLIMIT_FIX(RLIMIT_CPU);
} else { } else {
res= -11;
errno = EINVAL; errno = EINVAL;
} }
if(res){ if(res){
...@@ -313,7 +314,7 @@ CPCD::Process::do_exec() { ...@@ -313,7 +314,7 @@ CPCD::Process::do_exec() {
} }
/* Close all filedescriptors */ /* Close all filedescriptors */
for(i = STDERR_FILENO+1; i < getdtablesize(); i++) for(i = STDERR_FILENO+1; (int)i < getdtablesize(); i++)
close(i); close(i);
execv(m_path.c_str(), argv); execv(m_path.c_str(), argv);
......
...@@ -1494,6 +1494,7 @@ DbUtil::execUTIL_SEQUENCE_REQ(Signal* signal){ ...@@ -1494,6 +1494,7 @@ DbUtil::execUTIL_SEQUENCE_REQ(Signal* signal){
break; break;
default: default:
ndbrequire(false); ndbrequire(false);
prepOp = 0; // remove warning
} }
/** /**
......
...@@ -406,11 +406,11 @@ MgmtSrvr::MgmtSrvr(NodeId nodeId, ...@@ -406,11 +406,11 @@ MgmtSrvr::MgmtSrvr(NodeId nodeId,
_blockNumber(1), // Hard coded block number since it makes it easy to send _blockNumber(1), // Hard coded block number since it makes it easy to send
// signals to other management servers. // signals to other management servers.
_ownReference(0), _ownReference(0),
m_local_config(local_config),
m_allocated_resources(*this), m_allocated_resources(*this),
theSignalIdleList(NULL), theSignalIdleList(NULL),
theWaitState(WAIT_SUBSCRIBE_CONF), theWaitState(WAIT_SUBSCRIBE_CONF),
m_statisticsListner(this), m_statisticsListner(this)
m_local_config(local_config)
{ {
DBUG_ENTER("MgmtSrvr::MgmtSrvr"); DBUG_ENTER("MgmtSrvr::MgmtSrvr");
...@@ -967,6 +967,9 @@ MgmtSrvr::versionNode(int processId, bool abort, ...@@ -967,6 +967,9 @@ MgmtSrvr::versionNode(int processId, bool abort,
{ {
return sendVersionReq(processId); return sendVersionReq(processId);
} }
else
version= 0;
if(m_versionRec.callback != 0) if(m_versionRec.callback != 0)
m_versionRec.callback(processId, version, this,0); m_versionRec.callback(processId, version, this,0);
m_versionRec.inUse = false ; m_versionRec.inUse = false ;
......
...@@ -1252,7 +1252,7 @@ void ...@@ -1252,7 +1252,7 @@ void
MgmStatService::log(int eventType, const Uint32* theData, NodeId nodeId){ MgmStatService::log(int eventType, const Uint32* theData, NodeId nodeId){
Uint32 threshold = 0; Uint32 threshold = 0;
LogLevel::EventCategory cat; LogLevel::EventCategory cat= LogLevel::llInvalid;
int i; int i;
for(i = 0; (unsigned)i<EventLogger::matrixSize; i++){ for(i = 0; (unsigned)i<EventLogger::matrixSize; i++){
...@@ -1262,6 +1262,8 @@ MgmStatService::log(int eventType, const Uint32* theData, NodeId nodeId){ ...@@ -1262,6 +1262,8 @@ MgmStatService::log(int eventType, const Uint32* theData, NodeId nodeId){
break; break;
} }
} }
if (cat == LogLevel::llInvalid)
return;
char m_text[256]; char m_text[256];
EventLogger::getText(m_text, sizeof(m_text), eventType, theData, nodeId); EventLogger::getText(m_text, sizeof(m_text), eventType, theData, nodeId);
......
...@@ -74,11 +74,11 @@ int main(int argc, const char** argv){ ...@@ -74,11 +74,11 @@ int main(int argc, const char** argv){
ndbout << "-- Indexes -- " << endl; ndbout << "-- Indexes -- " << endl;
ndbout << "PRIMARY KEY("; ndbout << "PRIMARY KEY(";
unsigned j; unsigned j;
for (j= 0; j < pTab->getNoOfPrimaryKeys(); j++) for (j= 0; (int)j < pTab->getNoOfPrimaryKeys(); j++)
{ {
const NdbDictionary::Column * col = pTab->getColumn(j); const NdbDictionary::Column * col = pTab->getColumn(j);
ndbout << col->getName(); ndbout << col->getName();
if (j < pTab->getNoOfPrimaryKeys()-1) if ((int)j < pTab->getNoOfPrimaryKeys()-1)
ndbout << ", "; ndbout << ", ";
} }
ndbout << ") - UniqueHashIndex" << endl; ndbout << ") - UniqueHashIndex" << endl;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment