Explorar o código

[gdb]Change open flag

陈豪 %!s(int64=10) %!d(string=hai) anos
pai
achega
dd7fff2b31
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      components/gdb/hal_stub.c

+ 1 - 1
components/gdb/hal_stub.c

@@ -67,7 +67,7 @@ void gdb_set_device(const char* device_name)
     }
     }
 
 
     /* open this device and set the new device  */
     /* open this device and set the new device  */
-    if (rt_device_open(dev, RT_DEVICE_OFLAG_RDWR) == RT_EOK)
+    if (rt_device_open(dev, RT_DEVICE_OFLAG_RDWR | RT_DEVICE_FLAG_STREAM) == RT_EOK)
     {
     {
         gdb_dev = dev;   
         gdb_dev = dev;   
         gdb_serial = (struct rt_serial_device *)gdb_dev;
         gdb_serial = (struct rt_serial_device *)gdb_dev;