summaryrefslogtreecommitdiffstats
path: root/src/low-can-binding.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/low-can-binding.cpp')
-rw-r--r--src/low-can-binding.cpp8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/low-can-binding.cpp b/src/low-can-binding.cpp
index 8fc143c..bcbfc2c 100644
--- a/src/low-can-binding.cpp
+++ b/src/low-can-binding.cpp
@@ -48,8 +48,12 @@ const struct afb_binding_interface *binder_interface;
void on_no_clients(std::string message)
{
DiagnosticRequest* diag_req = configuration_t::instance().get_request_from_diagnostic_message(message);
- active_diagnostic_request_t* adr = configuration_t::instance().get_diagnostic_manager().find_recurring_request(diag_req);
- configuration_t::instance().get_diagnostic_manager().cleanup_request(adr, true);
+ if(diag_req != nullptr)
+ {
+ active_diagnostic_request_t* adr = configuration_t::instance().get_diagnostic_manager().find_recurring_request(diag_req);
+ if( adr != nullptr)
+ configuration_t::instance().get_diagnostic_manager().cleanup_request(adr, true);
+ }
}
///******************************************************************************