void GatewayMgr::start(QString password) { g_sm->checkCurrentOn(ServiceMgr::LOGIC); // check if (mdsm_ != nullptr || tdsm_ != nullptr) { BfDebug("mdsm_!= nullptr || tdsm_ != nullptr"); return; } // init mdsm password_ = password; if (!initMdSm()) { return; } if (!initTdSm()) { delete mdsm_; mdsm_ = nullptr; return; } startMdSm(); startTdSm(); return; }
bool CtpMgr::start(QString password) { // check if (mdsm_ != nullptr || tdsm_ != nullptr) { qFatal("mdsm_!= nullptr || tdsm_ != nullptr"); } // init mdsm password_ = password; if (!initMdSm()) { return false; } if (!initTdSm()) { delete mdsm_; mdsm_ = nullptr; return false; } startMdSm(); startTdSm(); return true; }