From fc11ad845a3d3d4c0d708b715cf9fb5e4c8fbd07 Mon Sep 17 00:00:00 2001 From: Paul Cristian Sarbu Date: Tue, 5 Mar 2024 18:11:00 +0100 Subject: exceptions handling: small improvements It is better to avoid empty catches when we have a reasonable way to log an (even unlikely) exception, even more so if memory allocations are involved. --- src/buildtool/serve_api/serve_service/target.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/buildtool/serve_api/serve_service/target.hpp') diff --git a/src/buildtool/serve_api/serve_service/target.hpp b/src/buildtool/serve_api/serve_service/target.hpp index 9ab10d09..df42a87b 100644 --- a/src/buildtool/serve_api/serve_service/target.hpp +++ b/src/buildtool/serve_api/serve_service/target.hpp @@ -118,7 +118,7 @@ class TargetService final : public justbuild::just_serve::Target::Service { /// also ensures the content has the expected format. /// \returns An error + data union, with a pair of grpc status at index 0 /// and the dispatch list stored as a JSON object at index 1. - auto GetDispatchList(ArtifactDigest const& dispatch_digest) + auto GetDispatchList(ArtifactDigest const& dispatch_digest) noexcept -> std::variant<::grpc::Status, dispatch_t>; }; -- cgit v1.2.3