summaryrefslogtreecommitdiffstats
path: root/source
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2008-03-28 10:19:21 +1100
committerAndrew Bartlett <abartlet@samba.org>2008-03-28 10:19:21 +1100
commit59d8d17093efac3a177a032f2e121ea6f43a96c8 (patch)
tree1b2d31581bf176374db7b190bf74cb06801c358b /source
parent5a740f4daa79cf1b5fc9f24e424ae50e10932f4b (diff)
parentf47df5761571dd5c36789fb2e225a1125ca0e8f7 (diff)
downloadsamba-59d8d17093efac3a177a032f2e121ea6f43a96c8.tar.gz
samba-59d8d17093efac3a177a032f2e121ea6f43a96c8.tar.xz
samba-59d8d17093efac3a177a032f2e121ea6f43a96c8.zip
Merge branch 'v4-0-test' of ssh://git.samba.org/data/git/samba into 4-0-local
Diffstat (limited to 'source')
-rw-r--r--source/lib/replace/test/os2_delete.c9
-rw-r--r--source/scripting/python/config.m42
-rw-r--r--source/scripting/python/samba/provision.py5
3 files changed, 12 insertions, 4 deletions
diff --git a/source/lib/replace/test/os2_delete.c b/source/lib/replace/test/os2_delete.c
index c6ef1800178..b45c135355a 100644
--- a/source/lib/replace/test/os2_delete.c
+++ b/source/lib/replace/test/os2_delete.c
@@ -39,8 +39,15 @@ static void create_files(void)
int i;
for (i=0;i<NUM_FILES;i++) {
char fname[40];
+ int fd;
sprintf(fname, TESTDIR "/test%u.txt", i);
- close(open(fname, O_CREAT|O_RDWR, 0600)) == 0 || FAILED("close");
+ fd = open(fname, O_CREAT|O_RDWR, 0600);
+ if (fd < 0) {
+ FAILED("open");
+ }
+ if (close(fd) != 0) {
+ FAILED("close");
+ }
}
}
diff --git a/source/scripting/python/config.m4 b/source/scripting/python/config.m4
index aac98ebc60d..3790071ba88 100644
--- a/source/scripting/python/config.m4
+++ b/source/scripting/python/config.m4
@@ -23,9 +23,7 @@ AC_DEFUN([TRY_LINK_PYTHON],
AC_TRY_LINK([
/* we have our own configure tests */
- #define Py_PYCONFIG_H 1
#include <Python.h>
- #include <stdlib.h>
],[
Py_InitModule(NULL, NULL);
],[
diff --git a/source/scripting/python/samba/provision.py b/source/scripting/python/samba/provision.py
index 47d00f8871c..e97ce694b4c 100644
--- a/source/scripting/python/samba/provision.py
+++ b/source/scripting/python/samba/provision.py
@@ -373,7 +373,10 @@ def load_or_make_smbconf(smbconf, setup_path, hostname, domain, realm, serverrol
lockdir_line = "lock dir = " + os.path.abspath(targetdir)
default_lp.set("lock dir", os.path.abspath(targetdir))
-
+ else:
+ privatedir_line = "private_dir = " + default_lp.get("private dir")
+ lockdir_line = "lock dir = " + default_lp.get("lock dir")
+
sysvol = os.path.join(default_lp.get("lock dir"), "sysvol")
netlogon = os.path.join(sysvol, realm.lower(), "scripts")