Michael Mckeown
2016-05-13 17:20:30 UTC
Was expecting to be able to catch a duplicate torrent error with this:
if ( auto at = libtorrent::alert_cast<
libtorrent::add_torrent_alert >( a ) )
{
int er = at->error.value();
if ( er == errors::error_code_enum::no_error )
{
std::cout << "add_torrent_alert " << a->message ( ) <<
" : ok \n";
}
else if ( er == errors::error_code_enum::duplicate_torrent )
{
std::cout << "add_torrent_alert " << a->message ( ) <<
" : duplicate_torrent\n";
}
}
but when I add the same magnet link again Libtorrent crashes with no
explanation, matters not if I use the add_torrent_alert or not.
Duplicates did work without crash with latest released build but I
rebuilt with the master today and the issue started when I was doing my
dupe dialog.
Thanks.
if ( auto at = libtorrent::alert_cast<
libtorrent::add_torrent_alert >( a ) )
{
int er = at->error.value();
if ( er == errors::error_code_enum::no_error )
{
std::cout << "add_torrent_alert " << a->message ( ) <<
" : ok \n";
}
else if ( er == errors::error_code_enum::duplicate_torrent )
{
std::cout << "add_torrent_alert " << a->message ( ) <<
" : duplicate_torrent\n";
}
}
but when I add the same magnet link again Libtorrent crashes with no
explanation, matters not if I use the add_torrent_alert or not.
Duplicates did work without crash with latest released build but I
rebuilt with the master today and the issue started when I was doing my
dupe dialog.
Thanks.