# HG changeset patch # User reimar # Date 1283968286 0 # Node ID 52a0d770adee3b3870e02c572c72f3c717aee8fb # Parent 4111548d28f981d83606f997d4a55ff9d5a7bdec Cosmetics: remove some useless {} diff -r 4111548d28f9 -r 52a0d770adee udp_sync.c --- a/udp_sync.c Wed Sep 08 17:50:05 2010 +0000 +++ b/udp_sync.c Wed Sep 08 17:51:26 2010 +0000 @@ -106,9 +106,8 @@ chars_received = recvfrom(sockfd, mesg, sizeof(mesg)-1, 0, (struct sockaddr *)&cliaddr, &len); - if (chars_received == -1) { + if (chars_received == -1) return 0; - } #if HAVE_WINSOCK2_H sock_flags = 0; @@ -122,9 +121,8 @@ (struct sockaddr *)&cliaddr, &len))) { chars_received = n; mesg[chars_received] = 0; - if (strcmp(mesg, "bye") == 0) { + if (strcmp(mesg, "bye") == 0) return 1; - } } if (chars_received > -1) { @@ -205,9 +203,8 @@ // without waiting. // UDP_TIMING_TOLERANCE is a small value that lets us consider // the master equal to us even if it's very slightly ahead. - if (udp_master_position + UDP_TIMING_TOLERANCE > my_position) { + if (udp_master_position + UDP_TIMING_TOLERANCE > my_position) break; - } // the remaining case is that we're slightly ahead of the master. // usually, it just means we called get_udp() before the datagram