aboutsummaryrefslogtreecommitdiff
path: root/src/gdb_packet.c
diff options
context:
space:
mode:
authorGareth McMullin2013-06-17 15:53:32 +1200
committerGareth McMullin2013-06-17 15:53:32 +1200
commit8c877d6dfa5aff2b70ce2c96ef6314bcae7a25c2 (patch)
treeedb96d39d96f3969796d54fa09ccca4827318395 /src/gdb_packet.c
parent2d63dd4b5b01df2406cda71ee1fb08968b14fd0a (diff)
Fix trailing whitespace everywhere.
Diffstat (limited to 'src/gdb_packet.c')
-rw-r--r--src/gdb_packet.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/gdb_packet.c b/src/gdb_packet.c
index 958572c..d43be42 100644
--- a/src/gdb_packet.c
+++ b/src/gdb_packet.c
@@ -34,7 +34,7 @@
#include "gdb_packet.h"
#include "hex_utils.h"
-int
+int
gdb_getpacket(unsigned char *packet, int size)
{
unsigned char c;
@@ -54,9 +54,9 @@ gdb_getpacket(unsigned char *packet, int size)
if(i == size) break; /* Oh shit */
if(c == '$') { /* Restart capture */
- i = 0;
- csum = 0;
- continue;
+ i = 0;
+ csum = 0;
+ continue;
}
if(c == '}') { /* escaped char */
c = gdb_if_getchar();
@@ -70,7 +70,7 @@ gdb_getpacket(unsigned char *packet, int size)
recv_csum[0] = gdb_if_getchar();
recv_csum[1] = gdb_if_getchar();
recv_csum[2] = 0;
-
+
/* return packet if checksum matches */
if(csum == strtol(recv_csum, NULL, 16)) break;
@@ -84,7 +84,7 @@ gdb_getpacket(unsigned char *packet, int size)
DEBUG("%s : ", __func__);
for(int j = 0; j < i; j++) {
c = packet[j];
- if ((c >= 32) && (c < 127))
+ if ((c >= 32) && (c < 127))
DEBUG("%c", c);
else
DEBUG("\\x%02X", c);
@@ -101,7 +101,7 @@ void gdb_putpacket(unsigned char *packet, int size)
unsigned char c;
char xmit_csum[3];
int tries = 0;
-
+
do {
#ifdef DEBUG_GDBPACKET
DEBUG("%s : ", __func__);
@@ -111,7 +111,7 @@ void gdb_putpacket(unsigned char *packet, int size)
for(i = 0; i < size; i++) {
c = packet[i];
#ifdef DEBUG_GDBPACKET
- if ((c >= 32) && (c < 127))
+ if ((c >= 32) && (c < 127))
DEBUG("%c", c);
else
DEBUG("\\x%02X", c);