diff options
author | ulfl <ulfl@f5534014-38df-0310-8fa8-9805f1628bb7> | 2005-04-19 22:32:52 +0000 |
---|---|---|
committer | ulfl <ulfl@f5534014-38df-0310-8fa8-9805f1628bb7> | 2005-04-19 22:32:52 +0000 |
commit | 6ffa6d4a0ea5337b6705de5fabe3aa4a34941617 (patch) | |
tree | ddfdaeb49ad3322cb6fd2ebd48a180ca8282efc8 /capture_ui_utils.h | |
parent | c28aa32ced174a21fbeaf029cf003700c0db086f (diff) |
fix some minor bugs with the current interface name:
-always show descriptive string in combo box
-correct the initialization, so cancelling the option dialog won't make trouble
git-svn-id: http://anonsvn.wireshark.org/wireshark/trunk@14144 f5534014-38df-0310-8fa8-9805f1628bb7
Diffstat (limited to 'capture_ui_utils.h')
-rw-r--r-- | capture_ui_utils.h | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/capture_ui_utils.h b/capture_ui_utils.h index f97defa890..e3b7bf7dc5 100644 --- a/capture_ui_utils.h +++ b/capture_ui_utils.h @@ -34,9 +34,9 @@ * if get_interface_list() supplies a description, use that, * otherwise use the interface name. * - * @param if_name The name if the interface. + * @param if_name The name of the interface. * - * @return The descriptive name. + * @return The descriptive name (must be g_free'd later) */ char *get_interface_descriptive_name(const char *if_name); @@ -45,7 +45,7 @@ char *get_interface_descriptive_name(const char *if_name); * @param if_list An interface list from get_interface_list(). * @param do_hide Hide the "hidden" interfaces. * - * @return A list of if_info_t structs. + * @return A list of if_info_t structs (use free_capture_combo_list() later). */ GList *build_capture_combo_list(GList *if_list, gboolean do_hide); @@ -63,8 +63,16 @@ void free_capture_combo_list(GList *combo_list); * This is usually the data from one of the list elements returned by * build_capture_combo_list(). * - * @return The raw interface name, sans description. + * @return The raw interface name, without description (must NOT be g_free'd later) */ char *get_if_name(char *if_text); +/** Convert plain interface name to the displayed name in the combo box. + * + * @param if_name The name of the interface. + * + * @return The descriptive name (must be g_free'd later) + */ +char * build_capture_combo_name(GList *if_list, gchar *if_name); + #endif |