mirror of
https://github.com/d47081/qBittorrent.git
synced 2025-01-25 14:04:23 +00:00
Fix possible crash when right-clicking on a torrent
This commit is contained in:
parent
797a4608bf
commit
7c580a87e2
@ -132,6 +132,7 @@ bool QTorrentHandle::first_last_piece_first() const {
|
|||||||
}
|
}
|
||||||
++index;
|
++index;
|
||||||
}
|
}
|
||||||
|
if(index >= torrent_handle::get_torrent_info().num_files()) return false;
|
||||||
file_entry media_file = torrent_handle::get_torrent_info().file_at(index);
|
file_entry media_file = torrent_handle::get_torrent_info().file_at(index);
|
||||||
int piece_size = torrent_handle::get_torrent_info().piece_length();
|
int piece_size = torrent_handle::get_torrent_info().piece_length();
|
||||||
Q_ASSERT(piece_size>0);
|
Q_ASSERT(piece_size>0);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user