added curly brackets to ensure ANSI C compliance when UIP_TCP is defined; some automatic whitespace removal

This commit is contained in:
adamdunkels 2008-10-15 07:59:34 +00:00
parent 647443cb9d
commit 91910f82dd

View File

@ -29,7 +29,7 @@
* This file is part of the Contiki operating system.
*
*
* $Id: tcpip.c,v 1.13 2008/10/14 09:40:56 julienabeille Exp $
* $Id: tcpip.c,v 1.14 2008/10/15 07:59:34 adamdunkels Exp $
*/
/**
* \file
@ -630,28 +630,30 @@ tcpip_uipcall(void)
#endif /* UIP_UDP */
#if UIP_TCP
static unsigned char i;
register struct listenport *l;
{
static unsigned char i;
register struct listenport *l;
/* If this is a connection request for a listening port, we must
mark the connection with the right process ID. */
if(uip_connected()) {
l = &s.listenports[0];
for(i = 0; i < UIP_LISTENPORTS; ++i) {
if(l->port == uip_conn->lport &&
l->p != PROCESS_NONE) {
ts->p = l->p;
ts->state = NULL;
break;
}
++l;
}
/* If this is a connection request for a listening port, we must
mark the connection with the right process ID. */
if(uip_connected()) {
l = &s.listenports[0];
for(i = 0; i < UIP_LISTENPORTS; ++i) {
if(l->port == uip_conn->lport &&
l->p != PROCESS_NONE) {
ts->p = l->p;
ts->state = NULL;
break;
}
++l;
}
/* Start the periodic polling, if it isn't already active. */
if(etimer_expired(&periodic)) {
etimer_restart(&periodic);
}
}
/* Start the periodic polling, if it isn't already active. */
if(etimer_expired(&periodic)) {
etimer_restart(&periodic);
}
}
}
#endif
if(ts->p != NULL) {