BUG#15512 crash during online add of API/SQL node

ndb/src/kernel/blocks/qmgr/QmgrMain.cpp:
  Only get_connect_address for connected nodes.
  
  (also cleanup whitespace)
This commit is contained in:
unknown 2005-12-06 11:25:53 +01:00
parent d447f881db
commit fc1c0f5635

View File

@ -2040,19 +2040,22 @@ Qmgr::execAPI_VERSION_REQ(Signal * signal) {
ApiVersionConf * conf = (ApiVersionConf *)req;
if(getNodeInfo(nodeId).m_connected)
{
conf->version = getNodeInfo(nodeId).m_version;
else
conf->version = 0;
conf->nodeId = nodeId;
struct in_addr in= globalTransporterRegistry.get_connect_address(nodeId);
conf->inet_addr= in.s_addr;
}
else
{
conf->version = 0;
conf->inet_addr= 0;
}
conf->nodeId = nodeId;
sendSignal(senderRef,
GSN_API_VERSION_CONF,
signal,
ApiVersionConf::SignalLength, JBB);
}