From 5f259126943f603354687d8fdc11d48585fc7fec Mon Sep 17 00:00:00 2001 From: Steven Siloti Date: Tue, 9 Jan 2018 13:49:56 -0800 Subject: [PATCH] remove unused infohash member in create_torrent --- include/libtorrent/create_torrent.hpp | 5 ----- src/create_torrent.cpp | 2 -- 2 files changed, 7 deletions(-) diff --git a/include/libtorrent/create_torrent.hpp b/include/libtorrent/create_torrent.hpp index 18580be19..0b1f779e5 100644 --- a/include/libtorrent/create_torrent.hpp +++ b/include/libtorrent/create_torrent.hpp @@ -321,11 +321,6 @@ namespace libtorrent { // dht nodes to add to the routing table/bootstrap from std::vector> m_nodes; - // the hash that identifies this torrent - // is mutable because it's calculated - // lazily - mutable sha1_hash m_info_hash; - // if a creation date is found in the torrent file // this will be set to that, otherwise it'll be // 1970, Jan 1 diff --git a/src/create_torrent.cpp b/src/create_torrent.cpp index ba705ffcb..ef0fed1be 100644 --- a/src/create_torrent.cpp +++ b/src/create_torrent.cpp @@ -425,7 +425,6 @@ namespace { boost::shared_array const info = ti.metadata(); int const size = ti.metadata_size(); m_info_dict.preformatted().assign(&info[0], &info[0] + size); - m_info_hash = ti.info_hash(); } entry create_torrent::generate() const @@ -670,7 +669,6 @@ namespace { std::vector buf; bencode(std::back_inserter(buf), info); - m_info_hash = hasher(buf).final(); return dict; }