mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-08-09 23:57:34 +02:00
sipjreen: turn stupid assert into a sensible error message
This commit is contained in:
@@ -139,11 +139,13 @@ JabberPlugin::~JabberPlugin()
|
|||||||
void
|
void
|
||||||
JabberPlugin::setProxy( const QNetworkProxy &proxy )
|
JabberPlugin::setProxy( const QNetworkProxy &proxy )
|
||||||
{
|
{
|
||||||
if(m_currentServer.isEmpty() || !(m_currentPort > 0))
|
qDebug() << Q_FUNC_INFO;
|
||||||
|
|
||||||
|
if( ( proxy.type() != QNetworkProxy::NoProxy ) && ( m_currentServer.isEmpty() || !(m_currentPort > 0) ) )
|
||||||
{
|
{
|
||||||
// patches are welcome in Jreen that implement jdns through proxy
|
// patches are welcome in Jreen that implement jdns through proxy
|
||||||
qDebug() << Q_FUNC_INFO << "Jreen proxy only works when you explicitly set host and port";
|
emit error( SipPlugin::ConnectionError,
|
||||||
Q_ASSERT(false);
|
errorMessage( tr( "You need to set hostname and port of your jabber server, if you want to use it through a proxy" ) ) );
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user