diff --git a/src/bittorrent.cpp b/src/bittorrent.cpp index 7ea4d4d29..022ba4a08 100644 --- a/src/bittorrent.cpp +++ b/src/bittorrent.cpp @@ -1604,10 +1604,10 @@ void bittorrent::readAlerts() { else if (tracker_reply_alert* p = dynamic_cast(a.get())) { QTorrentHandle h(p->handle); if(h.is_valid()){ - qDebug("Received a tracker reply from %s", h.current_tracker().toLocal8Bit().data()); + qDebug("Received a tracker reply from %s", p->url.c_str()); // Connection was successful now. Remove possible old errors QHash errors = trackersErrors.value(h.hash(), QHash()); - errors.remove(h.current_tracker()); + errors.remove(misc::toQString(p->url)); trackersErrors[h.hash()] = errors; } } else if (tracker_warning_alert* p = dynamic_cast(a.get())) { @@ -1615,10 +1615,9 @@ void bittorrent::readAlerts() { if(h.is_valid()){ // Connection was successful now. Remove possible old errors QHash errors = trackersErrors.value(h.hash(), QHash()); - errors.remove(h.current_tracker()); + errors[misc::toQString(p->url)] = misc::toQString(p->msg); trackersErrors[h.hash()] = errors; - qDebug("Received a tracker warning from %s: %s", h.current_tracker().toLocal8Bit().data(), p->msg.c_str()); - // XXX: The tracker warning is silently ignored... do something with it. + qDebug("Received a tracker warning from %s: %s", p->url.c_str(), p->msg.c_str()); } } else if (portmap_error_alert* p = dynamic_cast(a.get())) {