Fix a memory leak caused by the constness of the exceptionCause string in Yerbacon::Exception
This commit is contained in:
parent
659cdf4e80
commit
c696b440e7
@ -18,7 +18,7 @@
|
||||
namespace Yerbacon {
|
||||
consteval const char* getVersion() noexcept { return YBCON_VERSION; }
|
||||
class Exception: public std::exception {
|
||||
const std::string exceptionCause;
|
||||
std::string exceptionCause;
|
||||
public:
|
||||
[[nodiscard]] const char* what() const noexcept final {
|
||||
return exceptionCause.data();
|
||||
|
Loading…
Reference in New Issue
Block a user