1
0
mirror of https://github.com/samba-team/samba.git synced 2025-02-25 17:57:42 +03:00

debug: Only initialize gpfs wrapper when gpfs logging is enabled

This avoids unnecessary attempts to load libgpfs.so when it is not
needed.

Signed-off-by: Christof Schmitt <cs@samba.org>
Reviewed-by: Michael Tokarev <mjt@tls.msk.ru>
Reviewed-by: Volker Lendecke <vl@samba.org>

Autobuild-User(master): Volker Lendecke <vl@samba.org>
Autobuild-Date(master): Fri Apr 14 12:28:23 UTC 2023 on atb-devel-224
This commit is contained in:
Christof Schmitt 2023-04-13 11:13:00 -07:00 committed by Volker Lendecke
parent 31418f95d3
commit 45f026c45c

View File

@ -406,7 +406,9 @@ static void debug_lttng_log(int msg_level, const char *msg, size_t msg_len)
static void debug_gpfs_reload(bool enabled, bool previously_enabled,
const char *prog_name, char *option)
{
gpfswrap_init();
if (enabled) {
gpfswrap_init();
}
if (enabled && !previously_enabled) {
gpfswrap_init_trace();