From 5ffa7e4752993b1eb86117bb37854fe16ce928fc Mon Sep 17 00:00:00 2001 From: "Vladimir Golovnev (Glassez)" Date: Mon, 10 Jan 2022 08:30:05 +0300 Subject: [PATCH] Keep "torrent info" alive while generate .torrent file --- src/base/bittorrent/torrentinfo.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/base/bittorrent/torrentinfo.cpp b/src/base/bittorrent/torrentinfo.cpp index 3f6050e7a..2b5ff8f09 100644 --- a/src/base/bittorrent/torrentinfo.cpp +++ b/src/base/bittorrent/torrentinfo.cpp @@ -140,7 +140,7 @@ nonstd::expected TorrentInfo::saveToFile(const QString &path) con try { - const auto torrentCreator = lt::create_torrent(*nativeInfo()); + const auto torrentCreator = lt::create_torrent(*m_nativeInfo); const lt::entry torrentEntry = torrentCreator.generate(); const nonstd::expected result = Utils::IO::saveToFile(path, torrentEntry); if (!result)