comparison udp_sync.c @ 31999:378af88c0db0

Reindent.
author reimar
date Wed, 08 Sep 2010 18:17:35 +0000
parents 28fb4ef194f9
children 44c3f5637b8f
comparison
equal deleted inserted replaced
31998:28fb4ef194f9 31999:378af88c0db0
106 while (-1 != (n = recvfrom(sockfd, mesg, sizeof(mesg)-1, 0, 106 while (-1 != (n = recvfrom(sockfd, mesg, sizeof(mesg)-1, 0,
107 (struct sockaddr *)&cliaddr, &len))) { 107 (struct sockaddr *)&cliaddr, &len))) {
108 // flush out any further messages so we don't get behind 108 // flush out any further messages so we don't get behind
109 if (chars_received == -1) { 109 if (chars_received == -1) {
110 #if HAVE_WINSOCK2_H 110 #if HAVE_WINSOCK2_H
111 sock_flags = 0; 111 sock_flags = 0;
112 ioctlsocket(sockfd, FIONBIO, &sock_flags); 112 ioctlsocket(sockfd, FIONBIO, &sock_flags);
113 #else 113 #else
114 fcntl(sockfd, F_SETFL, sock_flags | O_NONBLOCK); 114 fcntl(sockfd, F_SETFL, sock_flags | O_NONBLOCK);
115 #endif 115 #endif
116 } 116 }
117 chars_received = n; 117 chars_received = n;
118 mesg[chars_received] = 0; 118 mesg[chars_received] = 0;
119 if (strcmp(mesg, "bye") == 0) 119 if (strcmp(mesg, "bye") == 0)