From owner-p4-projects@FreeBSD.ORG Mon Sep 29 02:53:15 2008 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 108BA1065689; Mon, 29 Sep 2008 02:53:15 +0000 (UTC) Delivered-To: perforce@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C8AD11065686 for ; Mon, 29 Sep 2008 02:53:14 +0000 (UTC) (envelope-from rfrench@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [IPv6:2001:4f8:fff6::29]) by mx1.freebsd.org (Postfix) with ESMTP id B6AFC8FC12 for ; Mon, 29 Sep 2008 02:53:14 +0000 (UTC) (envelope-from rfrench@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.14.3/8.14.3) with ESMTP id m8T2rE67016671 for ; Mon, 29 Sep 2008 02:53:14 GMT (envelope-from rfrench@FreeBSD.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.14.3/8.14.3/Submit) id m8T2rErw016669 for perforce@freebsd.org; Mon, 29 Sep 2008 02:53:14 GMT (envelope-from rfrench@FreeBSD.org) Date: Mon, 29 Sep 2008 02:53:14 GMT Message-Id: <200809290253.m8T2rErw016669@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to rfrench@FreeBSD.org using -f From: Ryan French To: Perforce Change Reviews Cc: Subject: PERFORCE change 150638 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 29 Sep 2008 02:53:15 -0000 http://perforce.freebsd.org/chv.cgi?CH=150638 Change 150638 by rfrench@rfrench_mpls on 2008/09/29 02:52:48 Made some changed to mpls-needle for debugging to check that the correctethertype was being assigned to the packet. Affected files ... .. //depot/projects/soc2008/rfrench_mpls/mpls-needle/mpls-needle.c#6 edit Differences ... ==== //depot/projects/soc2008/rfrench_mpls/mpls-needle/mpls-needle.c#6 (text+ko) ==== @@ -35,6 +35,7 @@ #include #include #include +#include #include #include #include @@ -366,32 +367,34 @@ /* * The following lines are used during debugging to check the values extracted from the * config file are correct. Uncomment these when debugging. - * printf("\nbuilt packets values\n"); - * - * printf("dst_mac = %s\n", ether_ntoa(&dst_mac)); - * printf("src_mac = %s\n", ether_ntoa(&src_mac)); + */ + printf("\nbuilt packets values\n"); + + printf("dst_mac = %s\n", ether_ntoa(&dst_mac)); + printf("src_mac = %s\n", ether_ntoa(&src_mac)); + printf("ethertype = %x\n", ntohs(eth->ether_type)); + + printf("ip_hl = %d\n", iph->ip_hl); + printf("ip_v = %d\n", iph->ip_v); + printf("ip_tos = %d\n", iph->ip_tos); + printf("ip_len = %d\n", iph->ip_len); + printf("ip_id = %d\n", iph->ip_id); + printf("ip_off = %d\n", iph->ip_off); + printf("ip_ttl = %d\n", iph->ip_ttl); + printf("ip_p = %d\n", iph->ip_p); + printf("ip_sum = %d\n", iph->ip_sum); + printf("ip_src = %s\n", inet_ntoa(iph->ip_src)); + printf("ip_dst = %s\n", inet_ntoa(iph->ip_dst)); + + printf("icmp_type = %d\n", icmph->icmp_type); + printf("icmp_code = %d\n", icmph->icmp_code); + printf("icmp_cksum = %d\n", icmph->icmp_cksum); - * printf("ip_hl = %d\n", iph->ip_hl); - * printf("ip_v = %d\n", iph->ip_v); - * printf("ip_tos = %d\n", iph->ip_tos); - * printf("ip_len = %d\n", iph->ip_len); - * printf("ip_id = %d\n", iph->ip_id); - * printf("ip_off = %d\n", iph->ip_off); - * printf("ip_ttl = %d\n", iph->ip_ttl); - * printf("ip_p = %d\n", iph->ip_p); - * printf("ip_sum = %d\n", iph->ip_sum); - * printf("ip_src = %s\n", inet_ntoa(iph->ip_src)); - * printf("ip_dst = %s\n", inet_ntoa(iph->ip_dst)); - * - * printf("icmp_type = %d\n", icmph->icmp_type); - * printf("icmp_code = %d\n", icmph->icmp_code); - * printf("icmp_cksum = %d\n", icmph->icmp_cksum); - * - * printf("mpls_label = %d\n", mpls_label); - * printf("mpls_qos = %d\n", mpls_qos); - * printf("mpls_bos_flag = %d\n", mpls_bos_flag); - * printf("mpls_ttl = %d\n", mpls_ttl); - */ + printf("mpls_label = %d\n", mpls_label); + printf("mpls_qos = %d\n", mpls_qos); + printf("mpls_bos_flag = %d\n", mpls_bos_flag); + printf("mpls_ttl = %d\n", mpls_ttl); + return 0; }