PERFORCE change 82805 for review
Victor Cruceru
soc-victor at FreeBSD.org
Mon Aug 29 21:28:01 GMT 2005
http://perforce.freebsd.org/chv.cgi?CH=82805
Change 82805 by soc-victor at soc-victor_82.76.158.176 on 2005/08/29 21:27:13
Renamed a macro.
Affected files ...
.. //depot/projects/soc2005/bsnmp/usr.sbin/bsnmpd/modules/snmp_tcp_udp46/tcp46_snmp.c#6 edit
.. //depot/projects/soc2005/bsnmp/usr.sbin/bsnmpd/modules/snmp_tcp_udp46/tcp_udp46.h#4 edit
.. //depot/projects/soc2005/bsnmp/usr.sbin/bsnmpd/modules/snmp_tcp_udp46/tcp_udp46_common.c#4 edit
.. //depot/projects/soc2005/bsnmp/usr.sbin/bsnmpd/modules/snmp_tcp_udp46/udp46_snmp.c#6 edit
Differences ...
==== //depot/projects/soc2005/bsnmp/usr.sbin/bsnmpd/modules/snmp_tcp_udp46/tcp46_snmp.c#6 (text+ko) ====
@@ -269,11 +269,11 @@
return 0;
}
if ( tp->xt_inp.inp_laddr.s_addr != INADDR_ANY ) {
- TCP46_DPRINTF((stderr, "V4 [%s] Skipped one listener (not an INADDR_ANY v4).\n ",
+ L4_DPRINTF((stderr, "V4 [%s] Skipped one listener (not an INADDR_ANY v4).\n ",
__func__));
return 0;
}
- TCP46_DPRINTF((stderr, "V4: [%s] Adding INADDR_ANY v4 listener with port %d.\n ",
+ L4_DPRINTF((stderr, "V4: [%s] Adding INADDR_ANY v4 listener with port %d.\n ",
__func__,
ntohs(tp->xt_inp.inp_lport)));
@@ -285,7 +285,7 @@
if ( _oid->index.subs[0] == IAT_ipv6 ) {
if ( _oid->index.subs[17] == ntohs(tp->xt_inp.inp_lport) &&
listener_oid->so_pgid == _oid->so_pgid) {
- TCP46_DPRINTF((stderr, "V4: [%s] Got listener with port %d.\n ",
+ L4_DPRINTF((stderr, "V4: [%s] Got listener with port %d.\n ",
__func__,
_oid->index.subs[5]));
@@ -322,11 +322,11 @@
return 0;
}
if ( !IN6_IS_ADDR_UNSPECIFIED(&tp->xt_inp.in6p_laddr) ) {
- TCP46_DPRINTF((stderr, "[%s] Skipped one listener (not an UNSPECIFIED v6).\n ",
+ L4_DPRINTF((stderr, "[%s] Skipped one listener (not an UNSPECIFIED v6).\n ",
__func__));
return 0;
}
- TCP46_DPRINTF((stderr, "[%s] Adding UNSPECIFIED v6 listener with port %d.\n ",
+ L4_DPRINTF((stderr, "[%s] Adding UNSPECIFIED v6 listener with port %d.\n ",
__func__,
ntohs(tp->xt_inp.in6p_lport)));
@@ -337,7 +337,7 @@
if ( _oid->index.subs[0] == IAT_ipv4 ) {
if ( _oid->index.subs[5] == ntohs(tp->xt_inp.in6p_lport) &&
listener_oid->so_pgid == _oid->so_pgid ) {
- TCP46_DPRINTF((stderr, "[%s] Got listener with port %d.\n ",
+ L4_DPRINTF((stderr, "[%s] Got listener with port %d.\n ",
__func__,
_oid->index.subs[5]));
@@ -510,7 +510,7 @@
tcp_udp46_state_g.listen_tcp_total = 0;
if (fetch_xfiles() != 0) {
- TCP46_DPRINTF((stderr, "[%s] Failed to fetch the xfiles\n ", __func__ ));
+ L4_DPRINTF((stderr, "[%s] Failed to fetch the xfiles\n ", __func__ ));
}
/*First count the endpoints*/
@@ -522,7 +522,7 @@
/* Ignore sockets for protocols other than the desired one. */
if ((( struct xtcpcb *)ptr)->xt_socket.xso_protocol != IPPROTO_TCP) {
- TCP46_DPRINTF((stderr, "[%s] One tcp4 conn. ignored (protocol missmatch: %d)\n ",
+ L4_DPRINTF((stderr, "[%s] One tcp4 conn. ignored (protocol missmatch: %d)\n ",
__func__,
((struct xinpcb *)ptr)->xi_socket.xso_protocol
));
@@ -532,7 +532,7 @@
/* Ignore PCBs which were freed during copyout. */
if (tp->xt_inp.inp_gencnt > tcp_udp46_state_g.tcp_xinpgen->xig_gen ) {
- TCP46_DPRINTF((stderr, "[%s] One tcp4 conn. ignored (freed during copyout)\n ",
+ L4_DPRINTF((stderr, "[%s] One tcp4 conn. ignored (freed during copyout)\n ",
__func__
));
@@ -558,7 +558,7 @@
}
}
- TCP46_DPRINTF((stderr, "[%s] Got %d tcp4 connections, %d tcp{4,6} connections, %d tcp{4,6} listeners.\n ",
+ L4_DPRINTF((stderr, "[%s] Got %d tcp4 connections, %d tcp{4,6} connections, %d tcp{4,6} listeners.\n ",
__func__,
tcp_udp46_state_g.tcp4_total,
tcp_udp46_state_g.all_tcp_total,
@@ -681,7 +681,7 @@
}
}
- TCP46_DPRINTF((stderr, "[%s] Got %d tcp{4,6} DISTINCT listeners.\n ",
+ L4_DPRINTF((stderr, "[%s] Got %d tcp{4,6} DISTINCT listeners.\n ",
__func__,
tcp_udp46_state_g.listen_tcp_total));
@@ -909,7 +909,7 @@
syslog(LOG_ERR, "%s: failed to delete the specified tcp connection: %m", __func__);
return -1;
} else {
- TCP46_DPRINTF((stderr, "[%s] one tcp connection deleted\n ",
+ L4_DPRINTF((stderr, "[%s] one tcp connection deleted\n ",
__func__));
syslog(LOG_INFO, "%s: one tcp connection deleted.", __func__);
==== //depot/projects/soc2005/bsnmp/usr.sbin/bsnmpd/modules/snmp_tcp_udp46/tcp_udp46.h#4 (text+ko) ====
@@ -49,12 +49,12 @@
/*a debug macro*/
#ifndef NDEBUG
-#define TCP46_DPRINTF(ARGS) do { \
- fprintf(stderr, "TCP46_DEBUG: "); \
- fprintf ARGS; \
+#define L4_DPRINTF(ARGS) do { \
+ fprintf(stderr, "TCP46_DEBUG: "); \
+ fprintf ARGS; \
} while (0)
#else
-#define TCP46_DPRINTF(ARGS)
+#define L4_DPRINTF(ARGS)
#endif /*NDEBUG*/
enum InetAddressType {
==== //depot/projects/soc2005/bsnmp/usr.sbin/bsnmpd/modules/snmp_tcp_udp46/tcp_udp46_common.c#4 (text+ko) ====
@@ -81,7 +81,7 @@
syslog(LOG_ERR, "kern.clockrate: wrong size");
return (-1);
}
- TCP46_DPRINTF((stderr, "[%s] done.\n", __func__));
+ L4_DPRINTF((stderr, "[%s] done.\n", __func__));
return (0);
}
@@ -153,7 +153,7 @@
}
- TCP46_DPRINTF((stderr, "[%s] done.\n", __func__));
+ L4_DPRINTF((stderr, "[%s] done.\n", __func__));
return (0);
}
@@ -165,7 +165,7 @@
static
void tcp_udp46_dump_v(void) {
/*nothing iteresting here for the time being*/
- TCP46_DPRINTF((stderr, "[%s] done.\n ", __func__));
+ L4_DPRINTF((stderr, "[%s] done.\n ", __func__));
}
/*
@@ -175,7 +175,7 @@
static
void tcp_udp46_config_v(void) {
/*nothing iteresting here for the time being*/
- TCP46_DPRINTF((stderr, "[%s] done.\n ", __func__));
+ L4_DPRINTF((stderr, "[%s] done.\n ", __func__));
}
@@ -188,7 +188,7 @@
goto LABEL_RETURN;
}
LABEL_RETURN:;
- TCP46_DPRINTF((stderr,"[%s] done.\n ", __func__));
+ L4_DPRINTF((stderr,"[%s] done.\n ", __func__));
}
@@ -222,7 +222,7 @@
syslog(LOG_ERR, "Failed to fetch the UDP data in tcp_udp46 module." );
}
- TCP46_DPRINTF((stderr, "[%s] done.\n ", __func__));
+ L4_DPRINTF((stderr, "[%s] done.\n ", __func__));
}
/*
==== //depot/projects/soc2005/bsnmp/usr.sbin/bsnmpd/modules/snmp_tcp_udp46/udp46_snmp.c#6 (text+ko) ====
@@ -374,7 +374,7 @@
return (-1);
}
- TCP46_DPRINTF((stderr, "[%s] Got %d len at net.inet.udp.pcblist .\n", __func__, len));
+ L4_DPRINTF((stderr, "[%s] Got %d len at net.inet.udp.pcblist .\n", __func__, len));
if (len > tcp_udp46_state_g.udp_xinpgen_len) {
if ((ptr = realloc(tcp_udp46_state_g.udp_xinpgen, len)) == NULL) {
@@ -396,7 +396,7 @@
tcp_udp46_state_g.all_udp_total = 0;
if (fetch_xfiles() != 0) {
- TCP46_DPRINTF((stderr, "[%s] Failed to fetch the xfiles\n ", __func__ ));
+ L4_DPRINTF((stderr, "[%s] Failed to fetch the xfiles\n ", __func__ ));
}
@@ -454,7 +454,7 @@
}
- TCP46_DPRINTF((stderr,
+ L4_DPRINTF((stderr,
"[%s] Got %d udp4 endpoints, %d udp{4,6} endpoints.\n",
__func__,
tcp_udp46_state_g.udp4_total,
More information about the p4-projects
mailing list