From d7eea2cc8e4bbe9af242d758e8f18c7b5e77a5cc Mon Sep 17 00:00:00 2001 From: "Uwe L. Korn" Date: Tue, 14 May 2013 11:25:27 +0200 Subject: [PATCH] Some more style changes --- src/libtomahawk/network/Servent.cpp | 8 ++++---- src/libtomahawk/network/Servent.h | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/libtomahawk/network/Servent.cpp b/src/libtomahawk/network/Servent.cpp index 3243acac8..758c548a4 100644 --- a/src/libtomahawk/network/Servent.cpp +++ b/src/libtomahawk/network/Servent.cpp @@ -420,7 +420,7 @@ Servent::registerPeer( const Tomahawk::peerinfo_ptr& peerInfo ) sipInfos.append( info ); } - if ( sipInfos.length() == 0 ) + if ( sipInfos.isEmpty() ) { // We are not visible via any IP, send a dummy SipInfo SipInfo info = SipInfo(); @@ -847,9 +847,9 @@ Servent::connectToPeer( const peerinfo_ptr& peerInfo ) void -Servent::connectToPeer(const peerinfo_ptr& peerInfo, const QList& sipInfoList, Connection* conn ) +Servent::connectToPeer(const peerinfo_ptr& peerInfo, const QList& sipInfos, Connection* conn ) { - if ( sipInfoList.isEmpty() ) + if ( sipInfos.isEmpty() ) { tLog( LOGVERBOSE ) << Q_FUNC_INFO << "No more possible SIP endpoints for " << conn->name() << " skipping."; // If a peerinfo was supplied and has a ControlConnection which should be destroyed, than use this @@ -860,7 +860,7 @@ Servent::connectToPeer(const peerinfo_ptr& peerInfo, const QList& sipIn delete conn; return; } - QList sipInfo = QList(sipInfoList); + QList sipInfo = QList(sipInfos); // Use first available SIP endpoint and remove it from the list SipInfo info = sipInfo.takeFirst(); if ( !info.isVisible() ) diff --git a/src/libtomahawk/network/Servent.h b/src/libtomahawk/network/Servent.h index 2243d6a92..27aabd710 100644 --- a/src/libtomahawk/network/Servent.h +++ b/src/libtomahawk/network/Servent.h @@ -90,7 +90,7 @@ public slots: public: void connectToPeer( const Tomahawk::peerinfo_ptr& ha ); - void connectToPeer(const Tomahawk::peerinfo_ptr &peerInfo, const QList& sipInfoList, Connection* conn ); + void connectToPeer(const Tomahawk::peerinfo_ptr &peerInfo, const QList& sipInfos, Connection* conn ); void reverseOfferRequest( ControlConnection* orig_conn, const QString &theirdbid, const QString& key, const QString& theirkey ); bool visibleExternally() const { return (!m_externalHostname.isNull()) || (m_externalAddresses.length() > 0); }