mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-08-09 15:47:38 +02:00
Knock down acl issue num 3: XMPP shows and auths against full jid with resource, sometimes
This commit is contained in:
@@ -169,6 +169,8 @@ SipHandler::onSipInfo( const QString& peerId, const SipInfo& info )
|
|||||||
{
|
{
|
||||||
tDebug() << Q_FUNC_INFO << "SIP Message:" << peerId << info;
|
tDebug() << Q_FUNC_INFO << "SIP Message:" << peerId << info;
|
||||||
|
|
||||||
|
QString barePeerId = peerId.left( peerId.indexOf( "/" ) );
|
||||||
|
|
||||||
/*
|
/*
|
||||||
If only one party is externally visible, connection is obvious
|
If only one party is externally visible, connection is obvious
|
||||||
If both are, peer with lowest IP address initiates the connection.
|
If both are, peer with lowest IP address initiates the connection.
|
||||||
@@ -179,11 +181,11 @@ SipHandler::onSipInfo( const QString& peerId, const SipInfo& info )
|
|||||||
if( !Servent::instance()->visibleExternally() ||
|
if( !Servent::instance()->visibleExternally() ||
|
||||||
Servent::instance()->externalAddress() <= info.host().hostName() )
|
Servent::instance()->externalAddress() <= info.host().hostName() )
|
||||||
{
|
{
|
||||||
qDebug() << "Initiate connection to" << peerId;
|
qDebug() << "Initiate connection to" << barePeerId;
|
||||||
Servent::instance()->connectToPeer( info.host().hostName(),
|
Servent::instance()->connectToPeer( info.host().hostName(),
|
||||||
info.port(),
|
info.port(),
|
||||||
info.key(),
|
info.key(),
|
||||||
peerId,
|
barePeerId,
|
||||||
info.uniqname() );
|
info.uniqname() );
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
@@ -199,7 +201,7 @@ SipHandler::onSipInfo( const QString& peerId, const SipInfo& info )
|
|||||||
m_peersSipInfos.insert( peerId, info );
|
m_peersSipInfos.insert( peerId, info );
|
||||||
}
|
}
|
||||||
|
|
||||||
void SipHandler::onSoftwareVersion(const QString& peerId, const QString& versionString)
|
void SipHandler::onSoftwareVersion( const QString& peerId, const QString& versionString )
|
||||||
{
|
{
|
||||||
m_peersSoftwareVersions.insert( peerId, versionString );
|
m_peersSoftwareVersions.insert( peerId, versionString );
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user