diff options
author | Guy Harris <guy@alum.mit.edu> | 2004-07-19 02:27:17 +0000 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2004-07-19 02:27:17 +0000 |
commit | 2ad97737fe50aef1b9fa291316b18621275b5e10 (patch) | |
tree | a40416ac4806fa00960df88df6adab7b75d42303 /gtk | |
parent | 84479319adb31b26f3b53accc30b532173489d63 (diff) |
Pull the address (and port and circuit type) stuff out of
"epan/packet_info.h" and put it in "epan/address.h".
Use the AT_ values from "epan/address.h" for address types in the
interface lists rather than having our own FAM_ enums.
svn path=/trunk/; revision=11427
Diffstat (limited to 'gtk')
-rw-r--r-- | gtk/capture_dlg.c | 9 | ||||
-rw-r--r-- | gtk/capture_if_dlg.c | 6 |
2 files changed, 9 insertions, 6 deletions
diff --git a/gtk/capture_dlg.c b/gtk/capture_dlg.c index 56d06f75d7..a3f088cbb3 100644 --- a/gtk/capture_dlg.c +++ b/gtk/capture_dlg.c @@ -280,17 +280,20 @@ set_link_type_list(GtkWidget *linktype_om, GtkWidget *entry) g_string_append(ip_str, ", "); ip_addr = (if_addr_t *)curr_ip->data; - switch (ip_addr->family) { + switch (ip_addr->type) { - case FAM_IPv4: + case AT_IPv4: g_string_append(ip_str, ip_to_str((guint8 *)&ip_addr->ip_addr.ip4_addr)); break; - case FAM_IPv6: + case AT_IPv6: g_string_append(ip_str, ip6_to_str((struct e_in6_addr *)&ip_addr->ip_addr.ip6_addr)); break; + + default: + g_assert_not_reached(); } } diff --git a/gtk/capture_if_dlg.c b/gtk/capture_if_dlg.c index b4cc35de86..aa60027229 100644 --- a/gtk/capture_if_dlg.c +++ b/gtk/capture_if_dlg.c @@ -442,13 +442,13 @@ capture_if_cb(GtkWidget *w _U_, gpointer d _U_) curr_ip = g_slist_nth(if_info->ip_addr, 0); if(curr_ip) { ip_addr = (if_addr_t *)curr_ip->data; - switch (ip_addr->family) { + switch (ip_addr->type) { - case FAM_IPv4: + case AT_IPv4: tmp_str = ip_to_str((guint8 *)&ip_addr->ip_addr.ip4_addr); break; - case FAM_IPv6: + case AT_IPv6: tmp_str = ip6_to_str((struct e_in6_addr *)&ip_addr->ip_addr.ip6_addr); break; |