summaryrefslogtreecommitdiffstats
path: root/low-can-binding/binding/low-can-subscription.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'low-can-binding/binding/low-can-subscription.cpp')
-rw-r--r--low-can-binding/binding/low-can-subscription.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/low-can-binding/binding/low-can-subscription.cpp b/low-can-binding/binding/low-can-subscription.cpp
index eb3f6c37..54cd314c 100644
--- a/low-can-binding/binding/low-can-subscription.cpp
+++ b/low-can-binding/binding/low-can-subscription.cpp
@@ -54,7 +54,8 @@ low_can_subscription_t& low_can_subscription_t::operator=(const low_can_subscrip
low_can_subscription_t::~low_can_subscription_t()
{
- socket_->close();
+ if(socket_)
+ socket_->close();
}
low_can_subscription_t::operator bool() const