X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/9104957deccc59e0e804215d5db498fabfd40d29..e91f26820b30a2d87b4c723e92eaebbd2dc5ce15:/src/simgrid/Exception.cpp diff --git a/src/simgrid/Exception.cpp b/src/simgrid/Exception.cpp index 134eefd51e..89781bd198 100644 --- a/src/simgrid/Exception.cpp +++ b/src/simgrid/Exception.cpp @@ -1,11 +1,11 @@ -/* Copyright (c) 2018-2020. The SimGrid Team. All rights reserved. */ +/* Copyright (c) 2018-2022. The SimGrid Team. All rights reserved. */ /* This program is free software; you can redistribute it and/or modify it * under the terms of the license (GNU LGPL) which comes with this package. */ #include -XBT_LOG_EXTERNAL_DEFAULT_CATEGORY(simix_context); +XBT_LOG_EXTERNAL_DEFAULT_CATEGORY(ker_actor); namespace simgrid { @@ -13,8 +13,17 @@ namespace simgrid { // Defining it here ensures that the exceptions are defined only in libsimgrid, but not in libsimgrid-java. // Doing otherwise naturally breaks things (at least on freebsd with clang). -Exception::~Exception() = default; -ForcefulKillException::~ForcefulKillException() = default; +Exception::~Exception() = default; +TimeoutException::~TimeoutException() = default; +HostFailureException::~HostFailureException() = default; +NetworkFailureException::~NetworkFailureException() = default; +StorageFailureException::~StorageFailureException() = default; +VmFailureException::~VmFailureException() = default; +CancelException::~CancelException() = default; +TracingError::~TracingError() = default; +ParseError::~ParseError() = default; +AssertionError::~AssertionError() = default; +ForcefulKillException::~ForcefulKillException() = default; void ForcefulKillException::do_throw() { @@ -27,8 +36,8 @@ bool ForcefulKillException::try_n_catch(const std::function& try_block) try { try_block(); res = true; - } catch (ForcefulKillException const&) { - XBT_DEBUG("Caught a ForcefulKillException"); + } catch (ForcefulKillException const& e) { + XBT_DEBUG("Caught a ForcefulKillException: %s", e.what()); res = false; } return res;