diff options
Diffstat (limited to 'protocols/JabberG')
-rw-r--r-- | protocols/JabberG/src/jabber_events.cpp | 2 | ||||
-rw-r--r-- | protocols/JabberG/src/jabber_iq_handlers.cpp | 2 | ||||
-rwxr-xr-x | protocols/JabberG/src/jabber_iqid.cpp | 2 | ||||
-rwxr-xr-x | protocols/JabberG/src/jabber_misc.cpp | 4 | ||||
-rwxr-xr-x | protocols/JabberG/src/jabber_opt.cpp | 4 | ||||
-rwxr-xr-x | protocols/JabberG/src/jabber_proto.cpp | 2 | ||||
-rwxr-xr-x | protocols/JabberG/src/jabber_proto.h | 2 |
7 files changed, 10 insertions, 8 deletions
diff --git a/protocols/JabberG/src/jabber_events.cpp b/protocols/JabberG/src/jabber_events.cpp index 3285ab91a1..237b1f6b50 100644 --- a/protocols/JabberG/src/jabber_events.cpp +++ b/protocols/JabberG/src/jabber_events.cpp @@ -145,7 +145,7 @@ void __cdecl CJabberProto::OnAddContactForever(MCONTACT hContact) XmlNode xPresence("presence"); xPresence << XATTR("to", jid) << XATTR("type", "subscribe");
ptrA myNick(getUStringA("Nick"));
- if (myNick != nullptr)
+ if (myNick != nullptr && !m_bIgnoreRoster)
xPresence << XCHILD("nick", myNick) << XATTR("xmlns", JABBER_FEAT_NICK);
m_ThreadInfo->send(xPresence);
diff --git a/protocols/JabberG/src/jabber_iq_handlers.cpp b/protocols/JabberG/src/jabber_iq_handlers.cpp index a6cff1e088..2761e53821 100644 --- a/protocols/JabberG/src/jabber_iq_handlers.cpp +++ b/protocols/JabberG/src/jabber_iq_handlers.cpp @@ -227,7 +227,7 @@ bool CJabberProto::OnRosterPushRequest(const TiXmlElement*, CJabberIqInfo *pInfo }
else db_unset(hContact, "CList", "MyHandle");
- if (!m_bIgnoreRosterGroups) {
+ if (!m_bIgnoreRoster) {
if (item->group != nullptr) {
Clist_GroupCreate(0, Utf2T(item->group));
db_set_utf(hContact, "CList", "Group", item->group);
diff --git a/protocols/JabberG/src/jabber_iqid.cpp b/protocols/JabberG/src/jabber_iqid.cpp index 8e1125b221..64fe8acbfc 100755 --- a/protocols/JabberG/src/jabber_iqid.cpp +++ b/protocols/JabberG/src/jabber_iqid.cpp @@ -442,7 +442,7 @@ void CJabberProto::OnIqResultGetRoster(const TiXmlElement *iqNode, CJabberIqInfo }
else UpdateSubscriptionInfo(hContact, item);
- if (!m_bIgnoreRosterGroups) {
+ if (!m_bIgnoreRoster) {
if (item->group != nullptr) {
Clist_GroupCreate(0, Utf2T(item->group));
diff --git a/protocols/JabberG/src/jabber_misc.cpp b/protocols/JabberG/src/jabber_misc.cpp index 9b2539fddc..e652d46c40 100755 --- a/protocols/JabberG/src/jabber_misc.cpp +++ b/protocols/JabberG/src/jabber_misc.cpp @@ -34,7 +34,9 @@ void CJabberProto::AddContactToRoster(const char *jid, const char *nick, const c {
XmlNodeIq iq("set", SerialNext());
TiXmlElement *query = iq << XQUERY(JABBER_FEAT_IQ_ROSTER)
- << XCHILD("item") << XATTR("jid", jid) << XATTR("name", nick);
+ << XCHILD("item") << XATTR("jid", jid);
+ if (nick && !m_bIgnoreRoster)
+ query << XATTR("name", nick);
if (grpName)
query << XCHILD("group", grpName);
m_ThreadInfo->send(iq);
diff --git a/protocols/JabberG/src/jabber_opt.cpp b/protocols/JabberG/src/jabber_opt.cpp index 2fbddc9c80..fda71360fd 100755 --- a/protocols/JabberG/src/jabber_opt.cpp +++ b/protocols/JabberG/src/jabber_opt.cpp @@ -784,7 +784,7 @@ public: m_otvOptions.AddOption(LPGENW("Other") L"/" LPGENW("Fix incorrect timestamps in incoming messages"), m_proto->m_bFixIncorrectTimestamps);
m_otvOptions.AddOption(LPGENW("Other") L"/" LPGENW("Disable frame"), m_proto->m_bDisableFrame);
m_otvOptions.AddOption(LPGENW("Other") L"/" LPGENW("Enable XMPP link processing (requires AssocMgr)"), m_proto->m_bProcessXMPPLinks);
- m_otvOptions.AddOption(LPGENW("Other") L"/" LPGENW("Keep contacts assigned to local groups (ignore roster group)"), m_proto->m_bIgnoreRosterGroups);
+ m_otvOptions.AddOption(LPGENW("Other") L"/" LPGENW("Ignore server roster (groups and nick names)"), m_proto->m_bIgnoreRoster);
m_otvOptions.AddOption(LPGENW("Security") L"/" LPGENW("Allow servers to request version (XEP-0092)"), m_proto->m_bAllowVersionRequests);
m_otvOptions.AddOption(LPGENW("Security") L"/" LPGENW("Show information about operating system in version replies"), m_proto->m_bShowOSVersion);
@@ -1150,7 +1150,7 @@ protected: break;
case ACC_OK:
- m_proto->m_bIgnoreRosterGroups = true;
+ m_proto->m_bIgnoreRoster = true;
m_proto->m_bUseSSL = false;
m_proto->m_bUseTLS = true;
diff --git a/protocols/JabberG/src/jabber_proto.cpp b/protocols/JabberG/src/jabber_proto.cpp index be945eb154..2a0db6ff00 100755 --- a/protocols/JabberG/src/jabber_proto.cpp +++ b/protocols/JabberG/src/jabber_proto.cpp @@ -108,7 +108,7 @@ CJabberProto::CJabberProto(const char *aProtoName, const wchar_t *aUserName) : m_bGcLogStatuses(this, "GcLogStatuses", false),
m_bHostNameAsResource(this, "HostNameAsResource", false),
m_bIgnoreMUCInvites(this, "IgnoreMUCInvites", false),
- m_bIgnoreRosterGroups(this, "IgnoreRosterGroups", false),
+ m_bIgnoreRoster(this, "IgnoreRosterGroups", false),
m_bInlinePictures(this, "InlinePictures", false),
m_bKeepAlive(this, "KeepAlive", true),
m_bLogChatstates(this, "LogChatstates", false),
diff --git a/protocols/JabberG/src/jabber_proto.h b/protocols/JabberG/src/jabber_proto.h index e9dc4d65eb..ed7ab8584a 100755 --- a/protocols/JabberG/src/jabber_proto.h +++ b/protocols/JabberG/src/jabber_proto.h @@ -205,7 +205,7 @@ struct CJabberProto : public PROTO<CJabberProto>, public IJabberInterface CMOption<bool> m_bGcLogStatuses;
CMOption<bool> m_bHostNameAsResource;
CMOption<bool> m_bIgnoreMUCInvites;
- CMOption<bool> m_bIgnoreRosterGroups;
+ CMOption<bool> m_bIgnoreRoster;
CMOption<bool> m_bInlinePictures;
CMOption<bool> m_bKeepAlive;
CMOption<bool> m_bLogChatstates;
|