aboutsummaryrefslogtreecommitdiffstats
path: root/low-can-binding/diagnostic/diagnostic-manager.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'low-can-binding/diagnostic/diagnostic-manager.cpp')
-rw-r--r--low-can-binding/diagnostic/diagnostic-manager.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/low-can-binding/diagnostic/diagnostic-manager.cpp b/low-can-binding/diagnostic/diagnostic-manager.cpp
index ba4b0c87..55e61084 100644
--- a/low-can-binding/diagnostic/diagnostic-manager.cpp
+++ b/low-can-binding/diagnostic/diagnostic-manager.cpp
@@ -188,6 +188,8 @@ void diagnostic_manager_t::find_and_erase(active_diagnostic_request_t* entry, st
void diagnostic_manager_t::cancel_request(active_diagnostic_request_t* entry)
{
entry->get_socket().close();
+ if(entry->get_handle())
+ delete(entry->get_handle());
delete entry;
entry = nullptr;
}