diff options
author | Gerald Combs <gerald@wireshark.org> | 1998-11-17 04:29:13 +0000 |
---|---|---|
committer | Gerald Combs <gerald@wireshark.org> | 1998-11-17 04:29:13 +0000 |
commit | 6ca358948b8c5aa99a4e0db8595f601ab834e76e (patch) | |
tree | 750ab11a6661c391b126d4ce990b7fc01cb98d46 /packet-udp.c | |
parent | 8d616b03429fe2185782f5153d7b187a44698b5d (diff) | |
download | wireshark-6ca358948b8c5aa99a4e0db8595f601ab834e76e.tar.gz wireshark-6ca358948b8c5aa99a4e0db8595f601ab834e76e.tar.bz2 wireshark-6ca358948b8c5aa99a4e0db8595f601ab834e76e.zip |
* Added column formatting functionality.
* Added check_col(), add_col_str() and add_col_fmt() to replace references
to ft->win_info.
* Added column prefs handling code.
svn path=/trunk/; revision=97
Diffstat (limited to 'packet-udp.c')
-rw-r--r-- | packet-udp.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/packet-udp.c b/packet-udp.c index cec5c5b9ee..8ac5c3ff24 100644 --- a/packet-udp.c +++ b/packet-udp.c @@ -1,7 +1,7 @@ /* packet-udp.c * Routines for UDP packet disassembly * - * $Id: packet-udp.c,v 1.6 1998/10/14 08:47:16 guy Exp $ + * $Id: packet-udp.c,v 1.7 1998/11/17 04:29:07 gerald Exp $ * * Ethereal - Network traffic analyzer * By Gerald Combs <gerald@zing.org> @@ -57,11 +57,11 @@ dissect_udp(const u_char *pd, int offset, frame_data *fd, GtkTree *tree) { uh_ulen = ntohs(uh.uh_ulen); uh_sum = ntohs(uh.uh_sum); - if (fd->win_info[COL_NUM]) { - strcpy(fd->win_info[COL_PROTOCOL], "UDP"); - sprintf(fd->win_info[COL_INFO], "Source port: %s Destination port: %s", + if (check_col(fd, COL_PROTOCOL)) + col_add_str(fd, COL_PROTOCOL, "UDP"); + if (check_col(fd, COL_INFO)) + col_add_fstr(fd, COL_INFO, "Source port: %s Destination port: %s", get_udp_port(uh_sport), get_udp_port(uh_dport)); - } if (tree) { ti = add_item_to_tree(GTK_WIDGET(tree), offset, 8, |