From a5549d630c3c261e7d52cb245d945e54f011a3e7 Mon Sep 17 00:00:00 2001 From: Gareth McMullin Date: Thu, 16 Oct 2014 13:19:34 -0700 Subject: Whitespace cleanup. --- src/platforms/stm32/gdb_if.c | 44 ++++++++++++++++++++++---------------------- 1 file changed, 22 insertions(+), 22 deletions(-) (limited to 'src/platforms/stm32/gdb_if.c') diff --git a/src/platforms/stm32/gdb_if.c b/src/platforms/stm32/gdb_if.c index 28bc4c8..482effe 100644 --- a/src/platforms/stm32/gdb_if.c +++ b/src/platforms/stm32/gdb_if.c @@ -67,8 +67,8 @@ void gdb_usb_out_cb(usbd_device *dev, uint8_t ep) { (void)ep; usbd_ep_nak_set(dev, CDCACM_GDB_ENDPOINT, 1); - count_new = usbd_ep_read_packet(dev, CDCACM_GDB_ENDPOINT, - double_buffer_out, CDCACM_PACKET_SIZE); + count_new = usbd_ep_read_packet(dev, CDCACM_GDB_ENDPOINT, + double_buffer_out, CDCACM_PACKET_SIZE); if(!count_new) { usbd_ep_nak_set(dev, CDCACM_GDB_ENDPOINT, 0); } @@ -77,19 +77,19 @@ void gdb_usb_out_cb(usbd_device *dev, uint8_t ep) unsigned char gdb_if_getchar(void) { - while(!(out_ptr < count_out)) { + while (!(out_ptr < count_out)) { /* Detach if port closed */ - if(!cdcacm_get_dtr()) + if (!cdcacm_get_dtr()) return 0x04; - while(cdcacm_get_config() != 1); - if (count_new) { - memcpy(buffer_out, double_buffer_out,count_new); - count_out = count_new; - count_new = 0; - out_ptr = 0; - usbd_ep_nak_set(usbdev, CDCACM_GDB_ENDPOINT, 0); - } + while (cdcacm_get_config() != 1); + if (count_new) { + memcpy(buffer_out, double_buffer_out,count_new); + count_out = count_new; + count_new = 0; + out_ptr = 0; + usbd_ep_nak_set(usbdev, CDCACM_GDB_ENDPOINT, 0); + } } return buffer_out[out_ptr++]; @@ -99,19 +99,19 @@ unsigned char gdb_if_getchar_to(int timeout) { timeout_counter = timeout/100; - if(!(out_ptr < count_out)) do { + if (!(out_ptr < count_out)) do { /* Detach if port closed */ - if(!cdcacm_get_dtr()) + if (!cdcacm_get_dtr()) return 0x04; - while(cdcacm_get_config() != 1); - if (count_new) { - memcpy(buffer_out, double_buffer_out,count_new); - count_out = count_new; - count_new = 0; - out_ptr = 0; - usbd_ep_nak_set(usbdev, CDCACM_GDB_ENDPOINT, 0); - } + while (cdcacm_get_config() != 1); + if (count_new) { + memcpy(buffer_out, double_buffer_out,count_new); + count_out = count_new; + count_new = 0; + out_ptr = 0; + usbd_ep_nak_set(usbdev, CDCACM_GDB_ENDPOINT, 0); + } } while(timeout_counter && !(out_ptr < count_out)); if(out_ptr < count_out) -- cgit v1.2.3