Enforce coding conventions in destiny via astyle

This commit is contained in:
Martin Lenders 2013-09-30 13:28:19 +02:00
parent 4825ec21b9
commit 6b999dc7bf
9 changed files with 118 additions and 118 deletions

View File

@ -1,5 +1,5 @@
/**
* Destiny transpor layer implementation
* Destiny transport layer implementation
*
* Copyright (C) 2013 INRIA.
*

View File

@ -63,7 +63,7 @@ void print_tcp_flags(tcp_hdr_t *tcp_header)
{
printf("FLAGS: ");
switch(tcp_header->reserved_flags) {
switch (tcp_header->reserved_flags) {
case TCP_ACK: {
printf("ACK ");
break;
@ -811,7 +811,7 @@ int32_t destiny_socket_send(int s, const void *buf, uint32_t len, int flags)
hwtimer_now();
net_msg_receive(&recv_msg);
switch(recv_msg.type) {
switch (recv_msg.type) {
case TCP_ACK: {
if (current_tcp_socket->tcp_control.no_of_retries == 0) {
calculate_rto(&current_tcp_socket->tcp_control,
@ -1082,7 +1082,7 @@ int destiny_socket_bind(int s, sockaddr6_t *addr, int addrlen)
if (exists_socket(s)) {
socket_t *current_socket = &get_socket(s)->socket_values;
switch(current_socket->domain) {
switch (current_socket->domain) {
case (PF_INET): {
/* Not provided */
return -1;
@ -1090,7 +1090,7 @@ int destiny_socket_bind(int s, sockaddr6_t *addr, int addrlen)
}
case (PF_INET6): {
switch(current_socket->type) {
switch (current_socket->type) {
/* TCP */
case (SOCK_STREAM): {
if ((current_socket->protocol == 0) ||

View File

@ -321,7 +321,7 @@ void tcp_packet_handler(void)
/* Remove reserved bits from tcp flags field */
uint8_t tcp_flags = tcp_header->reserved_flags & REMOVE_RESERVED;
switch(tcp_flags) {
switch (tcp_flags) {
case TCP_ACK: {
/* only ACK Bit set */
handle_tcp_ack_packet(ipv6_header, tcp_header, tcp_socket);

View File

@ -107,7 +107,7 @@ void check_sockets(void)
current_socket = get_socket(i);
if (is_tcp_socket(i)) {
switch(current_socket->socket_values.tcp_control.state) {
switch (current_socket->socket_values.tcp_control.state) {
case ESTABLISHED: {
handle_established(current_socket);
break;