Code Review
/
apps
/
agl-service-can-low-level.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
| inline |
side by side
Close socket by default when destroying object
[apps/agl-service-can-low-level.git]
/
CAN-binder
/
low-can-binding
/
utils
/
socketcan.cpp
diff --git
a/CAN-binder/low-can-binding/utils/socketcan.cpp
b/CAN-binder/low-can-binding/utils/socketcan.cpp
index
3aa34d2
..
71588a6
100644
(file)
--- a/
CAN-binder/low-can-binding/utils/socketcan.cpp
+++ b/
CAN-binder/low-can-binding/utils/socketcan.cpp
@@
-45,7
+45,10
@@
namespace utils
}
socketcan_t::~socketcan_t()
- {}
+ {
+ close();
+ socket_ = INVALID_SOCKET;
+ }
const struct sockaddr_can& socketcan_t::get_tx_address() const
{