Change-Id: Ice2325441474f1a075140e13dfffa0261106dff7
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
}
/// @brief Open the can socket and returning it
-/// @return -1
+/// @return -1 if something wrong.
int can_bus_dev_t::open()
{
const int canfd_on = 1;
struct timeval timeout;
DEBUG(binder_interface, "CAN Handler socket : %d", can_socket_.socket());
- if (can_socket_) return 0;
+ if (can_socket_)
+ return 0;
can_socket_.open(PF_CAN, SOCK_RAW, CAN_RAW);
if (can_socket_)