Convert some "col_add_str()" calls to "col_set_str()".

svn path=/trunk/; revision=4592
This commit is contained in:
Guy Harris 2002-01-21 23:35:32 +00:00
parent 9ff877d8fb
commit 961e0cdfa2
9 changed files with 25 additions and 25 deletions

View File

@ -1,7 +1,7 @@
/* packet-diameter.c
* Routines for Diameter packet disassembly
*
* $Id: packet-diameter.c,v 1.41 2002/01/21 07:36:33 guy Exp $
* $Id: packet-diameter.c,v 1.42 2002/01/21 23:35:31 guy Exp $
*
* Copyright (c) 2001 by David Frascone <dave@frascone.com>
*
@ -1059,7 +1059,7 @@ static guint32 dissect_diameter_common(tvbuff_t *tvb, size_t start, packet_info
/* Make entries in Protocol column and Info column on summary display */
if (check_col(pinfo->cinfo, COL_PROTOCOL))
col_add_str(pinfo->cinfo, COL_PROTOCOL, "Diameter");
col_set_str(pinfo->cinfo, COL_PROTOCOL, "Diameter");
if (check_col(pinfo->cinfo, COL_INFO))
col_clear(pinfo->cinfo, COL_INFO);

View File

@ -2,7 +2,7 @@
* Routines for NetWare's IPX
* Gilbert Ramirez <gram@alumni.rice.edu>
*
* $Id: packet-ipx.c,v 1.99 2002/01/21 07:36:35 guy Exp $
* $Id: packet-ipx.c,v 1.100 2002/01/21 23:35:31 guy Exp $
*
* Ethereal - Network traffic analyzer
* By Gerald Combs <gerald@ethereal.com>
@ -416,7 +416,7 @@ dissect_ipxrip(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
int cursor;
int available_length;
char *rip_type[3] = { "Request", "Response", "Unknown" };
static char *rip_type[3] = { "Request", "Response", "Unknown" };
if (check_col(pinfo->cinfo, COL_PROTOCOL))
col_set_str(pinfo->cinfo, COL_PROTOCOL, "IPX RIP");
@ -427,7 +427,7 @@ dissect_ipxrip(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
if (check_col(pinfo->cinfo, COL_INFO)) {
/* rip_types 0 and 1 are valid, anything else becomes 2 or "Unknown" */
col_add_str(pinfo->cinfo, COL_INFO, rip_type[MIN(operation, 2)]);
col_set_str(pinfo->cinfo, COL_INFO, rip_type[MIN(operation, 2)]);
}
if (tree) {
@ -741,7 +741,7 @@ dissect_ipxsap(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
struct sap_query query;
struct sap_server_ident server;
char *sap_type[4] = { "General Query", "General Response",
static char *sap_type[4] = { "General Query", "General Response",
"Nearest Query", "Nearest Response" };
if (check_col(pinfo->cinfo, COL_PROTOCOL))
@ -754,7 +754,7 @@ dissect_ipxsap(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
if (check_col(pinfo->cinfo, COL_INFO)) {
if (query.query_type >= 1 && query.query_type <= 4) {
col_add_str(pinfo->cinfo, COL_INFO, sap_type[query.query_type - 1]);
col_set_str(pinfo->cinfo, COL_INFO, sap_type[query.query_type - 1]);
}
else {
col_set_str(pinfo->cinfo, COL_INFO, "Unknown Packet Type");

View File

@ -4,7 +4,7 @@
* for ISAKMP (RFC 2407)
* Brad Robel-Forrest <brad.robel-forrest@watchguard.com>
*
* $Id: packet-isakmp.c,v 1.52 2002/01/21 07:36:35 guy Exp $
* $Id: packet-isakmp.c,v 1.53 2002/01/21 23:35:31 guy Exp $
*
* Ethereal - Network traffic analyzer
* By Gerald Combs <gerald@ethereal.com>
@ -340,15 +340,15 @@ dissect_isakmp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
if (encap_hdr->non_ike_marker[0] == 0xFF) {
if (check_col(pinfo->cinfo, COL_INFO))
col_add_str(pinfo->cinfo, COL_INFO, "UDP encapsulated IPSec - NAT Keepalive");
col_set_str(pinfo->cinfo, COL_INFO, "UDP encapsulated IPSec - NAT Keepalive");
return;
}
if (memcmp(encap_hdr->non_ike_marker,non_ike_marker,8) == 0) {
if (check_col(pinfo->cinfo, COL_INFO)) {
if (encap_hdr->esp_SPI != 0)
col_add_str(pinfo->cinfo, COL_INFO, "UDP encapsulated IPSec - ESP");
col_set_str(pinfo->cinfo, COL_INFO, "UDP encapsulated IPSec - ESP");
else
col_add_str(pinfo->cinfo, COL_INFO, "UDP encapsulated IPSec - AH");
col_set_str(pinfo->cinfo, COL_INFO, "UDP encapsulated IPSec - AH");
}
if (tree)
proto_tree_add_text(isakmp_tree, tvb, offset,

View File

@ -8,7 +8,7 @@
*
* Copyright 2000, Michael Tüxen <Michael.Tuexen@icn.siemens.de>
*
* $Id: packet-iua.c,v 1.11 2002/01/21 07:36:36 guy Exp $
* $Id: packet-iua.c,v 1.12 2002/01/21 23:35:32 guy Exp $
*
* Ethereal - Network traffic analyzer
* By Gerald Combs <gerald@ethereal.com>
@ -845,7 +845,7 @@ dissect_iua(tvbuff_t *message_tvb, packet_info *pinfo, proto_tree *tree)
/* make entry in the Protocol column on summary display */
if (check_col(pinfo->cinfo, COL_PROTOCOL))
col_add_str(pinfo->cinfo, COL_PROTOCOL, "IUA");
col_set_str(pinfo->cinfo, COL_PROTOCOL, "IUA");
/* In the interest of speed, if "tree" is NULL, don't do any work not
necessary to generate protocol tree items. */

View File

@ -2,7 +2,7 @@
* Routines for LPR and LPRng packet disassembly
* Gilbert Ramirez <gram@alumni.rice.edu>
*
* $Id: packet-lpd.c,v 1.33 2002/01/21 07:36:37 guy Exp $
* $Id: packet-lpd.c,v 1.34 2002/01/21 23:35:32 guy Exp $
*
* Ethereal - Network traffic analyzer
* By Gerald Combs <gerald@ethereal.com>
@ -61,7 +61,7 @@ dissect_lpd(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
/* This information comes from the LPRng HOWTO, which also describes
RFC 1179. http://www.astart.com/lprng/LPRng-HOWTO.html */
char *lpd_client_code[] = {
static char *lpd_client_code[] = {
"Unknown command",
"LPC: start print / jobcmd: abort",
"LPR: transfer a printer job / jobcmd: receive control file",
@ -73,7 +73,7 @@ dissect_lpd(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
"LPRng lpc: secure command transfer",
"LPRng lpq: verbose status information"
};
char *lpd_server_code[] = {
static char *lpd_server_code[] = {
"Success: accepted, proceed",
"Queue not accepting jobs",
"Queue temporarily full, retry later",
@ -99,7 +99,7 @@ dissect_lpd(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
if (check_col(pinfo->cinfo, COL_INFO)) {
if (lpr_packet_type == request) {
col_add_str(pinfo->cinfo, COL_INFO, lpd_client_code[code]);
col_set_str(pinfo->cinfo, COL_INFO, lpd_client_code[code]);
}
else if (lpr_packet_type == response) {
col_set_str(pinfo->cinfo, COL_INFO, "LPD response");

View File

@ -12,7 +12,7 @@
* Routines for NDMP dissection
* 2001 Ronnie Sahlberg (see AUTHORS for email)
*
* $Id: packet-ndmp.c,v 1.10 2002/01/21 07:36:37 guy Exp $
* $Id: packet-ndmp.c,v 1.11 2002/01/21 23:35:32 guy Exp $
*
* Ethereal - Network traffic analyzer
* By Gerald Combs <gerald@ethereal.com>
@ -2392,7 +2392,7 @@ dissect_ndmp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree)
if (first) {
if (check_col(pinfo->cinfo, COL_PROTOCOL))
col_add_str(pinfo->cinfo, COL_PROTOCOL, "NDMP");
col_set_str(pinfo->cinfo, COL_PROTOCOL, "NDMP");
if (check_col(pinfo->cinfo, COL_INFO))
col_clear(pinfo->cinfo, COL_INFO);
first = FALSE;

View File

@ -7,7 +7,7 @@
* This file is based on packet-aim.c, which is
* Copyright 2000, Ralf Hoelzer <ralf@well.com>
*
* $Id: packet-skinny.c,v 1.8 2002/01/21 07:36:42 guy Exp $
* $Id: packet-skinny.c,v 1.9 2002/01/21 23:35:32 guy Exp $
*
* Ethereal - Network traffic analyzer
* By Gerald Combs <gerald@ethereal.com>
@ -215,7 +215,7 @@ static void dissect_skinny(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
col_set_str(pinfo->cinfo, COL_PROTOCOL, "SKINNY");
if (check_col(pinfo->cinfo, COL_INFO))
col_add_str(pinfo->cinfo, COL_INFO, "Skinny Client Control Protocol");
col_set_str(pinfo->cinfo, COL_INFO, "Skinny Client Control Protocol");
/* In the interest of speed, if "tree" is NULL, don't do any work not
* necessary to generate protocol tree items. */

View File

@ -2,7 +2,7 @@
* Routines for cisco tacacs/xtacacs/tacacs+ packet dissection
* Copyright 2001, Paul Ionescu <paul@acorp.ro>
*
* $Id: packet-tacacs.c,v 1.19 2002/01/21 07:36:44 guy Exp $
* $Id: packet-tacacs.c,v 1.20 2002/01/21 23:35:32 guy Exp $
*
* Ethereal - Network traffic analyzer
* By Gerald Combs <gerald@ethereal.com>
@ -346,7 +346,7 @@ dissect_tacplus(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
if (check_col(pinfo->cinfo, COL_INFO))
{
col_add_str(pinfo->cinfo, COL_INFO,
col_set_str(pinfo->cinfo, COL_INFO,
request ? "Request" : "Response");
}

View File

@ -3,7 +3,7 @@
*
* Jochen Friedrich <jochen@scram.de>
*
* $Id: packet-zebra.c,v 1.18 2002/01/21 07:36:48 guy Exp $
* $Id: packet-zebra.c,v 1.19 2002/01/21 23:35:32 guy Exp $
*
* Ethereal - Network traffic analyzer
* By Gerald Combs <gerald@ethereal.com>
@ -479,7 +479,7 @@ dissect_zebra(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
offset = 0;
if (check_col(pinfo->cinfo, COL_INFO)) {
col_add_str(pinfo->cinfo, COL_INFO,
col_set_str(pinfo->cinfo, COL_INFO,
request? "ZEBRA Request" : "ZEBRA Reply");
}
if (tree) {