From: guy Date: Mon, 22 Oct 2007 19:39:12 +0000 (+0000) Subject: Precede the VCI values with VCI_, to avoid collisions (such as with X-Git-Tag: tcpdump-4.0.0~55 X-Git-Url: https://git.tcpdump.org/tcpdump/commitdiff_plain/a6cc6c6e4a9d3b8c3d2aa87dc15496e52214f07c Precede the VCI values with VCI_, to avoid collisions (such as with "PPC" as a definition on PowerPC machines). --- diff --git a/atmuni31.h b/atmuni31.h index c394d966..32acfb1e 100644 --- a/atmuni31.h +++ b/atmuni31.h @@ -29,18 +29,18 @@ * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. * - * @(#) $Header: /tcpdump/master/tcpdump/atmuni31.h,v 1.2 2002-08-05 07:47:23 guy Exp $ (LBL) + * @(#) $Header: /tcpdump/master/tcpdump/atmuni31.h,v 1.2.6.1 2007-10-22 19:39:12 guy Exp $ (LBL) */ /* Based on UNI3.1 standard by ATM Forum */ /* ATM traffic types based on VPI=0 and (the following VCI */ -#define PPC 0x05 /* Point-to-point signal msg */ -#define BCC 0x02 /* Broadcast signal msg */ -#define OAMF4SC 0x03 /* Segment OAM F4 flow cell */ -#define OAMF4EC 0x04 /* End-to-end OAM F4 flow cell */ -#define METAC 0x01 /* Meta signal msg */ -#define ILMIC 0x10 /* ILMI msg */ +#define VCI_PPC 0x05 /* Point-to-point signal msg */ +#define VCI_BCC 0x02 /* Broadcast signal msg */ +#define VCI_OAMF4SC 0x03 /* Segment OAM F4 flow cell */ +#define VCI_OAMF4EC 0x04 /* End-to-end OAM F4 flow cell */ +#define VCI_METAC 0x01 /* Meta signal msg */ +#define VCI_ILMIC 0x10 /* ILMI msg */ /* Q.2931 signalling messages */ #define CALL_PROCEED 0x02 /* call proceeding */ diff --git a/print-atm.c b/print-atm.c index ac83ac40..f50918bf 100644 --- a/print-atm.c +++ b/print-atm.c @@ -20,7 +20,7 @@ */ #ifndef lint static const char rcsid[] _U_ = - "@(#) $Header: /tcpdump/master/tcpdump/print-atm.c,v 1.48 2006-02-09 20:33:49 hannes Exp $ (LBL)"; + "@(#) $Header: /tcpdump/master/tcpdump/print-atm.c,v 1.48.2.1 2007-10-22 19:39:12 guy Exp $ (LBL)"; #endif #ifdef HAVE_CONFIG_H @@ -49,8 +49,8 @@ static const char rcsid[] _U_ = #define OAM_CELLTYPE_FUNCTYPE_LEN 1 struct tok oam_f_values[] = { - { OAMF4SC, "OAM F4 (segment)" }, - { OAMF4EC, "OAM F4 (end)" }, + { VCI_OAMF4SC, "OAM F4 (segment)" }, + { VCI_OAMF4EC, "OAM F4 (end)" }, { 0, NULL } }; @@ -295,24 +295,24 @@ atm_print(u_int vpi, u_int vci, u_int traftype, const u_char *p, u_int length, if (vpi == 0) { switch (vci) { - case PPC: + case VCI_PPC: sig_print(p, caplen); return; - case BCC: + case VCI_BCC: printf("broadcast sig: "); return; - case OAMF4SC: /* fall through */ - case OAMF4EC: + case VCI_OAMF4SC: /* fall through */ + case VCI_OAMF4EC: oam_print(p, length, ATM_OAM_HEC); return; - case METAC: + case VCI_METAC: printf("meta: "); return; - case ILMIC: + case VCI_ILMIC: printf("ilmi: "); snmp_print(p, length); return;