diff --git a/dist/tools/linux-border_router/flowcontrol.c b/dist/tools/linux-border_router/flowcontrol.c index e8b9bea4708776a887b5858e269a1b1b5e57d250..5eb000f9fed961ea00ce734f5acbc27303480231 100644 --- a/dist/tools/linux-border_router/flowcontrol.c +++ b/dist/tools/linux-border_router/flowcontrol.c @@ -150,8 +150,8 @@ void flowcontrol_deliver_from_tty(const border_packet_t *packet, int len) slot = &slwin_stat.recv_win[packet->seq_num % BORDER_RWS]; if (!in_window(packet->seq_num, - slwin_stat.next_exp, - slwin_stat.next_exp + BORDER_RWS - 1)) { + slwin_stat.next_exp, + slwin_stat.next_exp + BORDER_RWS - 1)) { return; } diff --git a/dist/tools/linux-border_router/multiplex.c b/dist/tools/linux-border_router/multiplex.c index edbfffd50834ef1a78e1470e3088c1a259ca1891..4e4f118ee94ce5f6f29935d1893edbf819078b1c 100644 --- a/dist/tools/linux-border_router/multiplex.c +++ b/dist/tools/linux-border_router/multiplex.c @@ -84,7 +84,7 @@ int readpacket(uint8_t *packet_buf, size_t size) if (esc) { esc = 0; - switch(byte) { + switch (byte) { case (END_ESC): { *line_buf_ptr++ = END; continue; @@ -125,7 +125,7 @@ int writepacket(uint8_t *packet_buf, size_t size) } while ((byte_ptr - packet_buf) < size) { - switch(*byte_ptr) { + switch (*byte_ptr) { case (END): { *byte_ptr = END_ESC; *tmp_ptr = ESC; @@ -158,7 +158,7 @@ int writepacket(uint8_t *packet_buf, size_t size) void demultiplex(const border_packet_t *packet, int len) { - switch(packet->type) { + switch (packet->type) { case (BORDER_PACKET_RAW_TYPE): { printf("\033[00;33m[via serial interface] %s\033[00m\n", ((unsigned char *)packet) + sizeof(border_packet_t) @@ -169,7 +169,7 @@ void demultiplex(const border_packet_t *packet, int len) case (BORDER_PACKET_L3_TYPE): { border_l3_header_t *l3_header_buf = (border_l3_header_t *)packet; - switch(l3_header_buf->ethertype) { + switch (l3_header_buf->ethertype) { case (ETHERTYPE_IPV6): { printf("INFO: IPv6-Packet %d received\n", l3_header_buf->seq_num); struct ip6_hdr *ip6_buf = (struct ip6_hdr *)(((unsigned char *)packet) + sizeof(border_l3_header_t)); @@ -188,7 +188,7 @@ void demultiplex(const border_packet_t *packet, int len) case (BORDER_PACKET_CONF_TYPE): { border_conf_header_t *conf_header_buf = (border_conf_header_t *)packet; - switch(conf_header_buf->conftype) { + switch (conf_header_buf->conftype) { case (BORDER_CONF_SYNACK): { printf("INFO: SYNACK-Packet %d received\n", conf_header_buf->seq_num); signal_connection_established();