From fd3d4d479af903ee5edf0b7757dcbf6bcd8c9a62 Mon Sep 17 00:00:00 2001 From: Chocobo1 Date: Thu, 8 Jul 2021 14:24:50 +0800 Subject: [PATCH] Suppress type narrowing warning on MSVC Fix up 45e31a153cf65390041059eb0a524ac296992629. --- src/base/bittorrent/torrentimpl.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/base/bittorrent/torrentimpl.cpp b/src/base/bittorrent/torrentimpl.cpp index a697bb30e..b4512d1b2 100644 --- a/src/base/bittorrent/torrentimpl.cpp +++ b/src/base/bittorrent/torrentimpl.cpp @@ -797,7 +797,7 @@ QVector TorrentImpl::filePriorities() const const std::vector fp = m_nativeHandle.get_file_priorities(); QVector ret; - ret.reserve(fp.size()); + ret.reserve(static_cast(fp.size())); std::transform(fp.cbegin(), fp.cend(), std::back_inserter(ret), [](const lt::download_priority_t priority) { return static_cast(toLTUnderlyingType(priority));