summaryrefslogtreecommitdiffstats
path: root/low-can-binding/utils/socketcan-j1939
diff options
context:
space:
mode:
Diffstat (limited to 'low-can-binding/utils/socketcan-j1939')
-rw-r--r--low-can-binding/utils/socketcan-j1939/socketcan-j1939.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/low-can-binding/utils/socketcan-j1939/socketcan-j1939.cpp b/low-can-binding/utils/socketcan-j1939/socketcan-j1939.cpp
index 38163254..660dffe4 100644
--- a/low-can-binding/utils/socketcan-j1939/socketcan-j1939.cpp
+++ b/low-can-binding/utils/socketcan-j1939/socketcan-j1939.cpp
@@ -168,6 +168,8 @@ namespace utils
{
socket_ = socketcan_t::open(PF_CAN, SOCK_DGRAM, CAN_J1939);
+ if (socket_ < 0)
+ return socket_;
define_tx_address(device_name, name, pgn, addr);