From 517d17dc6ad942e3d44aa8c8d82a054c1f82dc55 Mon Sep 17 00:00:00 2001 From: Eric Bollengier Date: Sat, 6 Nov 2010 11:10:49 +0100 Subject: [PATCH] Add bVarExePath to let plugins know about exepath --- bacula/src/filed/fd_plugins.c | 4 ++++ bacula/src/filed/fd_plugins.h | 3 ++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/bacula/src/filed/fd_plugins.c b/bacula/src/filed/fd_plugins.c index 44f9be503d..8fb472f8f6 100644 --- a/bacula/src/filed/fd_plugins.c +++ b/bacula/src/filed/fd_plugins.c @@ -35,6 +35,7 @@ #include "filed.h" extern CLIENT *me; +extern char *exepath; const int dbglvl = 150; #ifdef HAVE_WIN32 @@ -1023,6 +1024,9 @@ static bRC baculaGetValue(bpContext *ctx, bVariable var, void *value) case bVarRegexWhere: *(char **)value = jcr->RegexWhere; break; + case bVarExePath: + *(char **)value = exepath; + break; } return bRC_OK; } diff --git a/bacula/src/filed/fd_plugins.h b/bacula/src/filed/fd_plugins.h index 8fd4c6275d..059636e05d 100644 --- a/bacula/src/filed/fd_plugins.h +++ b/bacula/src/filed/fd_plugins.h @@ -177,7 +177,8 @@ typedef enum { bVarVssDllHandle = 12, bVarWorkingDir = 13, bVarWhere = 14, - bVarRegexWhere = 15 + bVarRegexWhere = 15, + bVarExePath = 16 } bVariable; /* Events that are passed to plugin */ -- 2.39.5