From 4286caccf3f7a70bafa29eab4f326093442eab2c Mon Sep 17 00:00:00 2001 From: Fovery <5240056+fovery@user.noreply.gitee.com> Date: Fri, 11 Sep 2020 16:04:01 +0800 Subject: [PATCH] =?UTF-8?q?1=E3=80=81=E5=85=B3=E9=97=ADcan=E8=AE=BE?= =?UTF-8?q?=E5=A4=87=E6=97=B6=EF=BC=8Cdetach=E6=8E=89=E4=BF=A1=E5=8F=B7?= =?UTF-8?q?=E9=87=8F=EF=BC=8C=E9=98=B2=E6=AD=A2=E9=87=8D=E6=96=B0=E6=89=93?= =?UTF-8?q?=E5=BC=80=E6=97=B6=E5=87=BA=E9=94=99=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- components/drivers/can/can.c | 1 + 1 file changed, 1 insertion(+) diff --git a/components/drivers/can/can.c b/components/drivers/can/can.c index 3d60dbaa55..0fa01e3a07 100644 --- a/components/drivers/can/can.c +++ b/components/drivers/can/can.c @@ -422,6 +422,7 @@ static rt_err_t rt_can_close(struct rt_device *dev) tx_fifo = (struct rt_can_tx_fifo *)can->can_tx; RT_ASSERT(tx_fifo != RT_NULL); + rt_sem_detach(&tx_fifo->sem); rt_free(tx_fifo); dev->open_flag &= ~RT_DEVICE_FLAG_INT_TX; can->can_tx = RT_NULL; -- Gitee