summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--source4/scripting/python/modules.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/source4/scripting/python/modules.c b/source4/scripting/python/modules.c
index 198b3ccf12..788df91bb4 100644
--- a/source4/scripting/python/modules.c
+++ b/source4/scripting/python/modules.c
@@ -20,6 +20,7 @@
#include <Python.h>
#include "includes.h"
#include "scripting/python/modules.h"
+#include "dynconfig/dynconfig.h"
extern void init_ldb(void);
extern void init_security(void);
@@ -89,6 +90,10 @@ bool py_update_path(const char *bindir)
return false;
}
+ if (!PySys_PathPrepend(py_path, dyn_PYTHONDIR)) {
+ return false;
+ }
+
asprintf(&newpath, "%s/../scripting/python", bindir);
if (!PySys_PathPrepend(py_path, newpath)) {
free(newpath);