From 8e140bc97e9846c7fb68758fe8a9300ea5f1dc43 Mon Sep 17 00:00:00 2001 From: Bill Currie Date: Sat, 30 Jul 2011 17:44:03 +0900 Subject: [PATCH] Use SYS_NET instead of SYS_DEV for networking debug prints. --- libs/net/net_main.c | 2 +- libs/net/nm/net_dgrm.c | 12 ++++++------ libs/net/nm/net_udp.c | 2 +- libs/net/nm/net_wins.c | 2 +- 4 files changed, 9 insertions(+), 9 deletions(-) diff --git a/libs/net/net_main.c b/libs/net/net_main.c index 8f7e4c337..b55c74287 100644 --- a/libs/net/net_main.c +++ b/libs/net/net_main.c @@ -788,7 +788,7 @@ NET_Init (void) } if (*my_tcpip_address) - Sys_MaskPrintf (SYS_DEV, "TCP/IP address %s\n", my_tcpip_address); + Sys_MaskPrintf (SYS_NET, "TCP/IP address %s\n", my_tcpip_address); } void diff --git a/libs/net/nm/net_dgrm.c b/libs/net/nm/net_dgrm.c index 4c90029da..09bf5ce49 100644 --- a/libs/net/nm/net_dgrm.c +++ b/libs/net/nm/net_dgrm.c @@ -309,7 +309,7 @@ Datagram_GetMessage (qsocket_t * sock) while (1) { length = - sfunc.Read (sock->socket, (byte *) & packetBuffer, NET_DATAGRAMSIZE, + sfunc.Read (sock->socket, (byte *) &packetBuffer, NET_DATAGRAMSIZE, &readaddr); // if ((rand() & 255) > 220) @@ -344,14 +344,14 @@ Datagram_GetMessage (qsocket_t * sock) if (flags & NETFLAG_UNRELIABLE) { if (sequence < sock->unreliableReceiveSequence) { - Sys_MaskPrintf (SYS_DEV, "Got a stale datagram\n"); + Sys_MaskPrintf (SYS_NET, "Got a stale datagram\n"); ret = 0; break; } if (sequence != sock->unreliableReceiveSequence) { count = sequence - sock->unreliableReceiveSequence; droppedDatagrams += count; - Sys_MaskPrintf (SYS_DEV, "Dropped %u datagram(s)\n", count); + Sys_MaskPrintf (SYS_NET, "Dropped %u datagram(s)\n", count); } sock->unreliableReceiveSequence = sequence + 1; @@ -366,15 +366,15 @@ Datagram_GetMessage (qsocket_t * sock) if (flags & NETFLAG_ACK) { if (sequence != (sock->sendSequence - 1)) { - Sys_MaskPrintf (SYS_DEV, "Stale ACK received\n"); + Sys_MaskPrintf (SYS_NET, "Stale ACK received\n"); continue; } if (sequence == sock->ackSequence) { sock->ackSequence++; if (sock->ackSequence != sock->sendSequence) - Sys_MaskPrintf (SYS_DEV, "ack sequencing error\n"); + Sys_MaskPrintf (SYS_NET, "ack sequencing error\n"); } else { - Sys_MaskPrintf (SYS_DEV, "Duplicate ACK received\n"); + Sys_MaskPrintf (SYS_NET, "Duplicate ACK received\n"); continue; } sock->sendMessageLength -= MAX_DATAGRAM; diff --git a/libs/net/nm/net_udp.c b/libs/net/nm/net_udp.c index 5a494356f..8a291a538 100644 --- a/libs/net/nm/net_udp.c +++ b/libs/net/nm/net_udp.c @@ -141,7 +141,7 @@ get_address (int sock) if (ioctl (sock, SIOCGIFADDR, &ifr[i]) == -1) continue; in_addr = (struct sockaddr_in *)&ifr[i].ifr_addr; - Sys_MaskPrintf (SYS_DEV, "%s: %s\n", ifr[i].ifr_name, + Sys_MaskPrintf (SYS_NET, "%s: %s\n", ifr[i].ifr_name, inet_ntoa (in_addr->sin_addr)); addr = *(unsigned *)&in_addr->sin_addr; if (addr != htonl (0x7f000001)) { diff --git a/libs/net/nm/net_wins.c b/libs/net/nm/net_wins.c index deb31f80b..9b7e1ce3e 100644 --- a/libs/net/nm/net_wins.c +++ b/libs/net/nm/net_wins.c @@ -202,7 +202,7 @@ WINS_Init (void) // determine my name if (pgethostname (buff, MAXHOSTNAMELEN) == SOCKET_ERROR) { - Sys_MaskPrintf (SYS_DEV, "Winsock TCP/IP Initialization failed.\n"); + Sys_MaskPrintf (SYS_NET, "Winsock TCP/IP Initialization failed.\n"); if (--winsock_initialized == 0) pWSACleanup (); return -1;