diff --git a/src/disk_io_thread.cpp b/src/disk_io_thread.cpp index f277aab83..2e80ad046 100644 --- a/src/disk_io_thread.cpp +++ b/src/disk_io_thread.cpp @@ -2344,7 +2344,7 @@ namespace libtorrent ret = piece_manager::fatal_disk_error; break; } - TORRENT_ASSERT(ret != -2 || !j.str.empty()); + TORRENT_ASSERT(ret != -2 || j.error); // if the check is not done, add it at the end of the job queue if (ret == piece_manager::need_full_check) @@ -2400,7 +2400,7 @@ namespace libtorrent #ifndef BOOST_NO_EXCEPTIONS try { #endif - TORRENT_ASSERT(ret != -2 || !j.str.empty() + TORRENT_ASSERT(ret != -2 || j.error || j.action == disk_io_job::hash); #if TORRENT_DISK_STATS if ((j.action == disk_io_job::read || j.action == disk_io_job::read_and_hash) diff --git a/src/torrent.cpp b/src/torrent.cpp index a3f9ec405..4c7dfcc92 100644 --- a/src/torrent.cpp +++ b/src/torrent.cpp @@ -1298,7 +1298,7 @@ namespace libtorrent } #if defined TORRENT_VERBOSE_LOGGING || defined TORRENT_LOGGING || defined TORRENT_ERROR_LOGGING (*m_ses.m_logger) << time_now_string() << ": fatal disk error [" - " error: " << j.str << + " error: " << j.error.message() << " torrent: " << torrent_file().name() << " ]\n"; #endif