diff options
author | Esben Norby <norby@cvs.openbsd.org> | 2008-05-06 02:47:21 +0000 |
---|---|---|
committer | Esben Norby <norby@cvs.openbsd.org> | 2008-05-06 02:47:21 +0000 |
commit | dd49685db4085fb21674b5b0575b7f7040b8995a (patch) | |
tree | 52a45d61eaccf4f2c42f705341bca16c47ff464d /sys/netmpls | |
parent | 344eebe6cf302f9d5ccb9beaea0370a2aa7831e3 (diff) |
fix debug output.
ok claudio@
Diffstat (limited to 'sys/netmpls')
-rw-r--r-- | sys/netmpls/mpls_input.c | 29 |
1 files changed, 17 insertions, 12 deletions
diff --git a/sys/netmpls/mpls_input.c b/sys/netmpls/mpls_input.c index ffac6f3228a..d17c245c0a3 100644 --- a/sys/netmpls/mpls_input.c +++ b/sys/netmpls/mpls_input.c @@ -1,4 +1,4 @@ -/* $OpenBSD: mpls_input.c,v 1.6 2008/05/02 12:40:29 claudio Exp $ */ +/* $OpenBSD: mpls_input.c,v 1.7 2008/05/06 02:47:20 norby Exp $ */ /* * Copyright (c) 2008 Claudio Jeker <claudio@openbsd.org> @@ -121,8 +121,10 @@ mpls_input(struct mbuf *m) smpls->smpls_in_ifindex = ifp->if_index; smpls->smpls_in_label = shim->shim_label & MPLS_LABEL_MASK; -printf("smpls af %d len %d in_label %d in_ifindex %d\n", smpls->smpls_family, - smpls->smpls_len, smpls->smpls_in_label, smpls->smpls_in_ifindex); + printf("smpls af %d len %d in_label %d in_ifindex %d\n", + smpls->smpls_family, smpls->smpls_len, + MPLS_LABEL_GET(smpls->smpls_in_label), + smpls->smpls_in_ifindex); rtalloc(&ro); /* XXX switch to rtalloc1() */ rt = ro.ro_rt; @@ -139,11 +141,14 @@ printf("smpls af %d len %d in_label %d in_ifindex %d\n", smpls->smpls_family, rt->rt_use++; smpls = satosmpls(rt_key(rt)); #ifdef MPLS_DEBUG -printf("route af %d len %d in_label %d in_ifindex %d\n", smpls->smpls_family, - smpls->smpls_len, MPLS_LABEL_GET(smpls->smpls_in_label), - smpls->smpls_in_ifindex); -printf("\top %d out_label %d out_ifindex %d\n", smpls->smpls_operation, - MPLS_LABEL_GET(smpls->smpls_out_label), smpls->smpls_out_ifindex); + printf("route af %d len %d in_label %d in_ifindex %d\n", + smpls->smpls_family, smpls->smpls_len, + MPLS_LABEL_GET(smpls->smpls_in_label), + smpls->smpls_in_ifindex); + printf("\top %d out_label %d out_ifindex %d\n", + smpls->smpls_operation, + MPLS_LABEL_GET(smpls->smpls_out_label), + smpls->smpls_out_ifindex); #endif switch (smpls->smpls_operation) { @@ -179,10 +184,10 @@ printf("\top %d out_label %d out_ifindex %d\n", smpls->smpls_operation, shim->shim_label = (shim->shim_label & ~MPLS_TTL_MASK) | ttl; #ifdef MPLS_DEBUG -printf("MPLS: sending on %s outlabel %x dst af %d in %d out %d\n", - ifp->if_xname, ntohl(shim->shim_label), smpls->smpls_family, - MPLS_LABEL_GET(smpls->smpls_in_label), - MPLS_LABEL_GET(smpls->smpls_out_label)); + printf("MPLS: sending on %s outlabel %x dst af %d in %d out %d\n", + ifp->if_xname, ntohl(shim->shim_label), smpls->smpls_family, + MPLS_LABEL_GET(smpls->smpls_in_label), + MPLS_LABEL_GET(smpls->smpls_out_label)); #endif (*ifp->if_output)(ifp, m, smplstosa(smpls), rt); |