From 3fa6ce55f4107ae79f108ec7ffbdbd9e26fca398 Mon Sep 17 00:00:00 2001 From: Tatsuhiro Tsujikawa Date: Tue, 24 Nov 2009 16:42:55 +0000 Subject: 2009-11-25 Tatsuhiro Tsujikawa Fixed the bug that trackers in BitTorrent Magnet URI are not inherited to generated RequestGroup. * src/UTMetadataPostDownloadHandler.cc * test/UTMetadataPostDownloadHandlerTest.cc --- src/UTMetadataPostDownloadHandler.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/UTMetadataPostDownloadHandler.cc') diff --git a/src/UTMetadataPostDownloadHandler.cc b/src/UTMetadataPostDownloadHandler.cc index 14f8ce6e..90ced69f 100644 --- a/src/UTMetadataPostDownloadHandler.cc +++ b/src/UTMetadataPostDownloadHandler.cc @@ -92,7 +92,8 @@ void UTMetadataPostDownloadHandler::getNextRequestGroups newAttrs[bittorrent::INFO_HASH].s()) { continue; } - if(!newAttrs.containsKey(bittorrent::ANNOUNCE_LIST)) { + assert(newAttrs[bittorrent::ANNOUNCE_LIST].isList()); + if(newAttrs[bittorrent::ANNOUNCE_LIST].size() == 0) { newAttrs[bittorrent::ANNOUNCE_LIST] = attrs[bittorrent::ANNOUNCE_LIST]; } -- cgit