From 9e9083cbedc0e98a03a0da370dd49375dc1cdc91 Mon Sep 17 00:00:00 2001 From: Pierre Ossman Date: Tue, 3 Sep 2024 07:31:15 +0200 Subject: Subclass exceptions from std::exception Make sure our exceptions are part of the standard exception class hierarchy. --- common/rdr/TLSInStream.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'common/rdr/TLSInStream.cxx') diff --git a/common/rdr/TLSInStream.cxx b/common/rdr/TLSInStream.cxx index c0252122..3418c68e 100644 --- a/common/rdr/TLSInStream.cxx +++ b/common/rdr/TLSInStream.cxx @@ -61,10 +61,10 @@ ssize_t TLSInStream::pull(gnutls_transport_ptr_t str, void* data, size_t size) gnutls_transport_set_errno(self->session, e.err); self->saved_exception = new SocketException(e); return -1; - } catch (Exception& e) { + } catch (std::exception& e) { vlog.error("Failure reading TLS data: %s", e.what()); gnutls_transport_set_errno(self->session, EINVAL); - self->saved_exception = new Exception(e); + self->saved_exception = new std::exception(e); return -1; } -- cgit v1.2.3