aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--tfshark.c36
-rw-r--r--tshark.c58
2 files changed, 47 insertions, 47 deletions
diff --git a/tfshark.c b/tfshark.c
index 7fef9a6bf3..02d390bb1a 100644
--- a/tfshark.c
+++ b/tfshark.c
@@ -796,22 +796,6 @@ main(int argc, char *argv[])
cmdarg_err_init(failure_message, failure_message_cont);
- /* Assemble the compile-time version information string */
- comp_info_str = g_string_new("Compiled ");
- get_compiled_version_info(comp_info_str, NULL, epan_get_compiled_version_info);
-
- /* Assemble the run-time version information string */
- runtime_info_str = g_string_new("Running ");
- get_runtime_version_info(runtime_info_str, NULL);
-
- /* Add it to the information to be reported on a crash. */
- ws_add_crash_info("TFShark %s\n"
- "\n"
- "%s"
- "\n"
- "%s",
- get_ws_vcs_version_info(), comp_info_str->str, runtime_info_str->str);
-
#ifdef _WIN32
arg_list_utf_16to8(argc, argv);
create_app_running_mutex();
@@ -838,6 +822,24 @@ main(int argc, char *argv[])
init_progfile_dir_error);
}
+ initialize_funnel_ops();
+
+ /* Assemble the compile-time version information string */
+ comp_info_str = g_string_new("Compiled ");
+ get_compiled_version_info(comp_info_str, NULL, epan_get_compiled_version_info);
+
+ /* Assemble the run-time version information string */
+ runtime_info_str = g_string_new("Running ");
+ get_runtime_version_info(runtime_info_str, NULL);
+
+ /* Add it to the information to be reported on a crash. */
+ ws_add_crash_info("TFShark %s\n"
+ "\n"
+ "%s"
+ "\n"
+ "%s",
+ get_ws_vcs_version_info(), comp_info_str->str, runtime_info_str->str);
+
/*
* In order to have the -X opts assigned before the wslua machine starts
* we need to call getopts before epan_init() gets called.
@@ -909,8 +911,6 @@ main(int argc, char *argv[])
(GLogLevelFlags)log_flags,
tfshark_log_handler, NULL /* user_data */);
- initialize_funnel_ops();
-
init_report_err(failure_message, open_failure_message, read_failure_message,
write_failure_message);
diff --git a/tshark.c b/tshark.c
index ced2908401..3537034366 100644
--- a/tshark.c
+++ b/tshark.c
@@ -1002,35 +1002,8 @@ main(int argc, char *argv[])
static const char optstring[] = OPTSTRING;
-#ifdef _WIN32
- /* Load wpcap if possible. Do this before collecting the run-time version information */
- load_wpcap();
-
- /* Warn the user if npf.sys isn't loaded. */
- if (!npf_sys_is_running() && get_windows_major_version() >= 6) {
- fprintf(stderr, "The NPF driver isn't running. You may have trouble "
- "capturing or\nlisting interfaces.\n");
- }
-#endif
-
cmdarg_err_init(failure_message, failure_message_cont);
- /* Assemble the compile-time version information string */
- comp_info_str = g_string_new("Compiled ");
- get_compiled_version_info(comp_info_str, NULL, epan_get_compiled_version_info);
-
- /* Assemble the run-time version information string */
- runtime_info_str = g_string_new("Running ");
- get_runtime_version_info(runtime_info_str, get_tshark_runtime_info);
-
- /* Add it to the information to be reported on a crash. */
- ws_add_crash_info("TShark %s\n"
- "\n"
- "%s"
- "\n"
- "%s",
- get_ws_vcs_version_info(), comp_info_str->str, runtime_info_str->str);
-
#ifdef _WIN32
arg_list_utf_16to8(argc, argv);
create_app_running_mutex();
@@ -1057,6 +1030,35 @@ main(int argc, char *argv[])
init_progfile_dir_error);
}
+ initialize_funnel_ops();
+
+#ifdef _WIN32
+ /* Load wpcap if possible. Do this before collecting the run-time version information */
+ load_wpcap();
+
+ /* Warn the user if npf.sys isn't loaded. */
+ if (!npf_sys_is_running() && get_windows_major_version() >= 6) {
+ fprintf(stderr, "The NPF driver isn't running. You may have trouble "
+ "capturing or\nlisting interfaces.\n");
+ }
+#endif
+
+ /* Assemble the compile-time version information string */
+ comp_info_str = g_string_new("Compiled ");
+ get_compiled_version_info(comp_info_str, NULL, epan_get_compiled_version_info);
+
+ /* Assemble the run-time version information string */
+ runtime_info_str = g_string_new("Running ");
+ get_runtime_version_info(runtime_info_str, get_tshark_runtime_info);
+
+ /* Add it to the information to be reported on a crash. */
+ ws_add_crash_info("TShark %s\n"
+ "\n"
+ "%s"
+ "\n"
+ "%s",
+ get_ws_vcs_version_info(), comp_info_str->str, runtime_info_str->str);
+
/*
* In order to have the -X opts assigned before the wslua machine starts
* we need to call getopts before epan_init() gets called.
@@ -1141,8 +1143,6 @@ main(int argc, char *argv[])
tshark_log_handler, NULL /* user_data */);
#endif
- initialize_funnel_ops();
-
init_report_err(failure_message, open_failure_message, read_failure_message,
write_failure_message);