From 5ec5da3f683de88d9aef3e886280af7039163c42 Mon Sep 17 00:00:00 2001 From: Guy Harris Date: Thu, 3 Mar 2016 13:35:40 -0800 Subject: [PATCH] Add missing initialization calls. Do the same thing editcap does; we need to know, for example, whether we were invoked with elevated privileges, so we know whether to pay attention to environment variables when loading plugins. Fix program name, and add a comment from editcap, while we're at it. Change-Id: Ia092331de129d86783a2600be21cff746d4ed5e3 Reviewed-on: https://code.wireshark.org/review/14334 Reviewed-by: Guy Harris --- mergecap.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/mergecap.c b/mergecap.c index cfcc1a6d73..56258253ed 100644 --- a/mergecap.c +++ b/mergecap.c @@ -324,9 +324,16 @@ main(int argc, char *argv[]) "%s", get_ws_vcs_version_info(), comp_info_str->str, runtime_info_str->str); + /* + * Get credential information for later use. + */ + init_process_policies(); + init_open_routines(); + #ifdef HAVE_PLUGINS + /* Register wiretap plugins */ if ((init_progfile_dir_error = init_progfile_dir(argv[0], main))) { - g_warning("captype: init_progfile_dir(): %s", init_progfile_dir_error); + g_warning("mergecap: init_progfile_dir(): %s", init_progfile_dir_error); g_free(init_progfile_dir_error); } else { /* Register all the plugin types we have. */ -- 2.34.1