forked from premiere/premiere-libtorrent
fix build with exceptions disabled
This commit is contained in:
parent
353ab20280
commit
77dcc5363f
|
@ -40,14 +40,15 @@ POSSIBILITY OF SUCH DAMAGE.
|
|||
namespace libtorrent { namespace aux {
|
||||
|
||||
template <typename T, typename... Args>
|
||||
void TORRENT_NO_RETURN throw_ex(Args&&... args)
|
||||
{
|
||||
#ifdef BOOST_NO_EXCEPTIONS
|
||||
void TORRENT_NO_RETURN throw_ex(Args&&...) {
|
||||
std::terminate();
|
||||
#else
|
||||
throw T(std::forward<Args>(args)...);
|
||||
#endif
|
||||
}
|
||||
#else
|
||||
void TORRENT_NO_RETURN throw_ex(Args&&... args) {
|
||||
throw T(std::forward<Args>(args)...);
|
||||
}
|
||||
#endif
|
||||
}}
|
||||
|
||||
#endif
|
||||
|
|
|
@ -483,12 +483,11 @@ namespace libtorrent {
|
|||
using boost::system::generic_category;
|
||||
using boost::system::system_category;
|
||||
|
||||
#ifndef BOOST_NO_EXCEPTIONS
|
||||
using boost::system::system_error;
|
||||
|
||||
#ifndef TORRENT_NO_DEPRECATE
|
||||
using system_error = boost::system::system_error;
|
||||
#ifndef BOOST_NO_EXCEPTIONS
|
||||
|
||||
#ifndef TORRENT_NO_DEPRECATE
|
||||
TORRENT_DEPRECATED
|
||||
inline boost::system::error_category& get_libtorrent_category()
|
||||
{ return libtorrent_category(); }
|
||||
|
|
Loading…
Reference in New Issue