print-token.c (162021) | print-token.c (172686) |
---|---|
1/* 2 * Copyright (c) 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996 3 * The Regents of the University of California. All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that: (1) source code distributions 7 * retain the above copyright notice and this paragraph in its entirety, (2) 8 * distributions including binary code include the above copyright notice and --- 9 unchanged lines hidden (view full) --- 18 * WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF 19 * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. 20 * 21 * Hacked version of print-ether.c Larry Lile <lile@stdio.com> 22 * 23 * Further tweaked to more closely resemble print-fddi.c 24 * Guy Harris <guy@alum.mit.edu> 25 * | 1/* 2 * Copyright (c) 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996 3 * The Regents of the University of California. All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that: (1) source code distributions 7 * retain the above copyright notice and this paragraph in its entirety, (2) 8 * distributions including binary code include the above copyright notice and --- 9 unchanged lines hidden (view full) --- 18 * WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF 19 * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. 20 * 21 * Hacked version of print-ether.c Larry Lile <lile@stdio.com> 22 * 23 * Further tweaked to more closely resemble print-fddi.c 24 * Guy Harris <guy@alum.mit.edu> 25 * |
26 * $FreeBSD: head/contrib/tcpdump/print-token.c 162021 2006-09-04 20:25:04Z sam $ | 26 * $FreeBSD: head/contrib/tcpdump/print-token.c 172686 2007-10-16 02:31:48Z mlaier $ |
27 */ 28#ifndef lint 29static const char rcsid[] _U_ = | 27 */ 28#ifndef lint 29static const char rcsid[] _U_ = |
30 "@(#) $Header: /tcpdump/master/tcpdump/print-token.c,v 1.25.2.1 2005/07/07 01:24:40 guy Exp $"; | 30 "@(#) $Header: /tcpdump/master/tcpdump/print-token.c,v 1.25.2.2 2005/11/13 12:13:01 guy Exp $"; |
31#endif 32 33#ifdef HAVE_CONFIG_H 34#include "config.h" 35#endif 36 37#include <tcpdump-stdinc.h> 38 --- 111 unchanged lines hidden (view full) --- 150 151 /* Skip over token ring MAC header and routing information */ 152 hdr_len += route_len; 153 length -= hdr_len; 154 p += hdr_len; 155 caplen -= hdr_len; 156 157 /* Frame Control field determines interpretation of packet */ | 31#endif 32 33#ifdef HAVE_CONFIG_H 34#include "config.h" 35#endif 36 37#include <tcpdump-stdinc.h> 38 --- 111 unchanged lines hidden (view full) --- 150 151 /* Skip over token ring MAC header and routing information */ 152 hdr_len += route_len; 153 length -= hdr_len; 154 p += hdr_len; 155 caplen -= hdr_len; 156 157 /* Frame Control field determines interpretation of packet */ |
158 extracted_ethertype = 0; | |
159 if (FRAME_TYPE(trp) == TOKEN_FC_LLC) { 160 /* Try to print the LLC-layer header & higher layers */ 161 if (llc_print(p, length, caplen, ESRC(&ehdr), EDST(&ehdr), 162 &extracted_ethertype) == 0) { 163 /* ether_type not known, print raw packet */ 164 if (!eflag) 165 token_hdr_print(trp, 166 length + TOKEN_HDRLEN + route_len, --- 31 unchanged lines hidden --- | 158 if (FRAME_TYPE(trp) == TOKEN_FC_LLC) { 159 /* Try to print the LLC-layer header & higher layers */ 160 if (llc_print(p, length, caplen, ESRC(&ehdr), EDST(&ehdr), 161 &extracted_ethertype) == 0) { 162 /* ether_type not known, print raw packet */ 163 if (!eflag) 164 token_hdr_print(trp, 165 length + TOKEN_HDRLEN + route_len, --- 31 unchanged lines hidden --- |