Explorar o código

Merge pull request #158 from grissiom/finsh-fix

finsh: unregister rx_indicate when closing the device
Bernard Xiong %!s(int64=11) %!d(string=hai) anos
pai
achega
1cb4ee74fb
Modificáronse 1 ficheiros con 1 adicións e 0 borrados
  1. 1 0
      components/finsh/shell.c

+ 1 - 0
components/finsh/shell.c

@@ -131,6 +131,7 @@ void finsh_set_device(const char* device_name)
 		{
 			/* close old finsh device */
 			rt_device_close(shell->device);
+            rt_device_set_rx_indicate(dev, RT_NULL);
 		}
 
 		shell->device = dev;