Commit b8493cd6 authored by unknown's avatar unknown
Browse files

BUG#19318 valgrind: memory leak in ndb_mgmd

2nd part of the patch

fix functions called by ndbd to deal with memory allocation properly. 


ndb/src/mgmapi/mgmapi.cpp:
  in get_configuration() - get a copy to return instead of just passing one back and loosing some memory
ndb/src/mgmsrv/ConfigInfo.cpp:
  clean up after ourselves in constructor
parent 87b8bf22
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1808,7 +1808,7 @@ ndb_mgm_get_configuration(NdbMgmHandle handle, unsigned int version) {
    }

    delete prop;
    return (ndb_mgm_configuration*)cvf.m_cfg;
    return (ndb_mgm_configuration*)cvf.getConfigValues();
  } while(0);

  delete prop;
+1 −0
Original line number Diff line number Diff line
@@ -2344,6 +2344,7 @@ ConfigInfo::ConfigInfo()
      ndbout << "Edit file " << __FILE__ << "." << endl;
      require(false);
    }
    delete section;
  }
}