*
* $Id$
*
- * Ethereal - Network traffic analyzer
- * By Gerald Combs <gerald@ethereal.com>
+ * Wireshark - Network traffic analyzer
+ * By Gerald Combs <gerald@wireshark.org>
* Copyright 1998 Gerald Combs
*
* This program is free software; you can redistribute it and/or
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
-/* This module provides rpc call/reply SRT statistics to ethereal,
+/* This module provides rpc call/reply SRT statistics to Wireshark,
* and displays them graphically.
- * It is only used by ethereal and not tethereal
+ * It is only used by Wireshark and not tshark
*
* It serves as an example on how to use the tap api.
*/
#include <epan/epan.h>
#include <epan/stat_cmd_args.h>
-#include "stat_menu.h"
+#include "../stat_menu.h"
+#include "gui_stat_menu.h"
#include "simple_dialog.h"
#include "dlg_utils.h"
#include "gui_utils.h"
/* When called, this function will create a new instance of gtk-dcerpcstat.
*/
static void
-gtk_dcerpcstat_init(const char *optarg)
+gtk_dcerpcstat_init(const char *optarg, void* userdata _U_)
{
rpcstat_t *rs;
guint32 i, max_procs;
filter=NULL;
}
} else {
- fprintf(stderr, "ethereal: invalid \"-z dcerpc,srt,<uuid>,<major version>.<minor version>[,<filter>]\" argument\n");
+ fprintf(stderr, "wireshark: invalid \"-z dcerpc,srt,<uuid>,<major version>.<minor version>[,<filter>]\" argument\n");
exit(1);
}
if (major < 0 || major > 65535) {
- fprintf(stderr,"ethereal: dcerpcstat_init() Major version number %d is invalid - must be positive and <= 65535\n", major);
+ fprintf(stderr,"wireshark: dcerpcstat_init() Major version number %d is invalid - must be positive and <= 65535\n", major);
exit(1);
}
if (minor < 0 || minor > 65535) {
- fprintf(stderr,"ethereal: dcerpcstat_init() Minor version number %d is invalid - must be positive and <= 65535\n", minor);
+ fprintf(stderr,"wireshark: dcerpcstat_init() Minor version number %d is invalid - must be positive and <= 65535\n", minor);
exit(1);
}
ver = major;
rs->prog=dcerpc_get_proto_name(&uuid, ver);
if(!rs->prog){
g_free(rs);
- fprintf(stderr,"ethereal: dcerpcstat_init() Protocol with uuid:%08x-%04x-%04x-%02x%02x-%02x%02x%02x%02x%02x%02x v%u not supported\n",uuid.Data1,uuid.Data2,uuid.Data3,uuid.Data4[0],uuid.Data4[1],uuid.Data4[2],uuid.Data4[3],uuid.Data4[4],uuid.Data4[5],uuid.Data4[6],uuid.Data4[7],ver);
+ fprintf(stderr,"wireshark: dcerpcstat_init() Protocol with uuid:%08x-%04x-%04x-%02x%02x-%02x%02x%02x%02x%02x%02x v%u not supported\n",uuid.Data1,uuid.Data2,uuid.Data3,uuid.Data4[0],uuid.Data4[1],uuid.Data4[2],uuid.Data4[3],uuid.Data4[4],uuid.Data4[5],uuid.Data4[6],uuid.Data4[7],ver);
exit(1);
}
hf_opnum=dcerpc_get_proto_hf_opnum(&uuid, ver);
gtk_widget_show_all(rs->win);
window_present(rs->win);
- cf_retap_packets(&cfile);
+ cf_retap_packets(&cfile, FALSE);
}
g_string_sprintfa(str, ",%s", filter);
}
- gtk_dcerpcstat_init(str->str);
+ gtk_dcerpcstat_init(str->str,NULL);
g_string_free(str, TRUE);
}
static construct_args_t args = {
"Service Response Time Statistics Filter",
FALSE,
- FALSE
+ FALSE,
+ FALSE
};
/* if the window is already open, bring it to front and
return;
}
- dlg=dlg_window_new("Ethereal: Compute DCE-RPC SRT statistics");
+ dlg=dlg_window_new("Wireshark: Compute DCE-RPC SRT statistics");
gtk_window_set_default_size(GTK_WINDOW(dlg), 400, -1);
dlg_box=gtk_vbox_new(FALSE, 10);
filter_box=gtk_hbox_new(FALSE, 3);
/* Filter label */
- filter_bt=BUTTON_NEW_FROM_STOCK(ETHEREAL_STOCK_DISPLAY_FILTER_ENTRY);
+ filter_bt=BUTTON_NEW_FROM_STOCK(WIRESHARK_STOCK_DISPLAY_FILTER_ENTRY);
SIGNAL_CONNECT(filter_bt, "clicked", display_filter_construct_cb, &args);
gtk_box_pack_start(GTK_BOX(filter_box), filter_bt, FALSE, FALSE, 0);
gtk_widget_show(filter_bt);
OBJECT_SET_DATA(filter_bt, E_FILT_TE_PTR_KEY, filter_entry);
/* button box */
- bbox = dlg_button_row_new(ETHEREAL_STOCK_CREATE_STAT, GTK_STOCK_CANCEL, NULL);
+ bbox = dlg_button_row_new(WIRESHARK_STOCK_CREATE_STAT, GTK_STOCK_CANCEL, NULL);
gtk_box_pack_start(GTK_BOX(dlg_box), bbox, FALSE, FALSE, 0);
gtk_widget_show(bbox);
- start_button = OBJECT_GET_DATA(bbox, ETHEREAL_STOCK_CREATE_STAT);
+ start_button = OBJECT_GET_DATA(bbox, WIRESHARK_STOCK_CREATE_STAT);
SIGNAL_CONNECT_OBJECT(start_button, "clicked",
dcerpcstat_start_button_clicked, NULL);
void
register_tap_listener_gtkdcerpcstat(void)
{
- register_stat_cmd_arg("dcerpc,srt,", gtk_dcerpcstat_init);
+ register_stat_cmd_arg("dcerpc,srt,", gtk_dcerpcstat_init,NULL);
register_stat_menu_item("DCE-RPC...", REGISTER_STAT_GROUP_RESPONSE_TIME,
gtk_dcerpcstat_cb, NULL, NULL, NULL);