diff options
author | saturneric <[email protected]> | 2023-12-15 09:04:59 +0000 |
---|---|---|
committer | saturneric <[email protected]> | 2023-12-15 09:04:59 +0000 |
commit | f5cf83e4b3fdf1e9ae82b00f39e45e189809c419 (patch) | |
tree | cc7d9b764b0274cfce5830e22a1ecc23678bd091 /src/core/function/basic/ChannelObject.cpp | |
parent | fix: slove issues on memory and add asan support for debug (diff) | |
download | GpgFrontend-f5cf83e4b3fdf1e9ae82b00f39e45e189809c419.tar.gz GpgFrontend-f5cf83e4b3fdf1e9ae82b00f39e45e189809c419.zip |
fix: slove some issues on memory and intilizations
Diffstat (limited to '')
-rw-r--r-- | src/core/function/basic/ChannelObject.cpp | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/src/core/function/basic/ChannelObject.cpp b/src/core/function/basic/ChannelObject.cpp index 7a41d4d1..3f040ca6 100644 --- a/src/core/function/basic/ChannelObject.cpp +++ b/src/core/function/basic/ChannelObject.cpp @@ -28,13 +28,20 @@ #include "ChannelObject.h" +#include <ostream> +#include <utility> +#include <iostream> + namespace GpgFrontend { ChannelObject::ChannelObject() noexcept = default; -ChannelObject::ChannelObject(int channel) : channel_(channel) {} +ChannelObject::ChannelObject(int channel, std::string type) + : channel_(channel), type_(std::move(type)) {} -ChannelObject::~ChannelObject() noexcept = default; +ChannelObject::~ChannelObject() noexcept { + std::cout << "deleting channel object: " << type_ << std::endl; +} void ChannelObject::SetChannel(int channel) { this->channel_ = channel; } |