canbus: isotp: fix asserts to check rx and tx addr
Previous implementation contained a typo so that only the rx address was checked. Signed-off-by: Martin Jäger <martin@libre.solar>
This commit is contained in:
parent
b6fd177d92
commit
ade6cc4a71
1 changed files with 2 additions and 2 deletions
|
@ -557,7 +557,7 @@ int isotp_bind(struct isotp_recv_ctx *ctx, const struct device *can_dev,
|
|||
|
||||
__ASSERT(ctx, "ctx is NULL");
|
||||
__ASSERT(can_dev, "CAN device is NULL");
|
||||
__ASSERT(rx_addr && rx_addr, "RX or TX addr is NULL");
|
||||
__ASSERT(rx_addr && tx_addr, "RX or TX addr is NULL");
|
||||
__ASSERT(opts, "OPTS is NULL");
|
||||
|
||||
ctx->can_dev = can_dev;
|
||||
|
@ -1106,7 +1106,7 @@ static int send(struct isotp_send_ctx *ctx, const struct device *can_dev,
|
|||
|
||||
__ASSERT_NO_MSG(ctx);
|
||||
__ASSERT_NO_MSG(can_dev);
|
||||
__ASSERT_NO_MSG(rx_addr && rx_addr);
|
||||
__ASSERT_NO_MSG(rx_addr && tx_addr);
|
||||
|
||||
if (complete_cb) {
|
||||
ctx->fin_cb.cb = complete_cb;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue