diff --git a/src/discoinforesponder.cpp b/src/discoinforesponder.cpp index 891ef958cfc731223f5d030fc003f1dea594087a..0e694feb6ff45922b3f9fc618c5de6b2e6e649cf 100644 --- a/src/discoinforesponder.cpp +++ b/src/discoinforesponder.cpp @@ -26,16 +26,20 @@ #include "Swiften/Queries/IQRouter.h" #include "Swiften/Elements/DiscoInfo.h" #include "Swiften/Swiften.h" +#include "transport/config.h" using namespace Swift; using namespace boost; namespace Transport { -DiscoInfoResponder::DiscoInfoResponder(Swift::IQRouter *router) : Swift::GetResponder(router) { - m_transportInfo.addIdentity(DiscoInfo::Identity("libtransport", "gateway", "identity")); +DiscoInfoResponder::DiscoInfoResponder(Swift::IQRouter *router, Config *config) : Swift::GetResponder(router) { + m_config = config; + m_transportInfo.addIdentity(DiscoInfo::Identity(CONFIG_STRING(m_config, "identity.name"), + CONFIG_STRING(m_config, "identity.category"), + CONFIG_STRING(m_config, "identity.type"))); - m_buddyInfo.addIdentity(DiscoInfo::Identity("libtransport", "client", "pc")); + m_buddyInfo.addIdentity(DiscoInfo::Identity(CONFIG_STRING(m_config, "identity.name"), "client", "pc")); std::list features; features.push_back("jabber:iq:register"); features.push_back("jabber:iq:gateway");