summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lib/util/tests/file.c2
-rw-r--r--libcli/nbt/tools/nmblookup.c (renamed from libcli/nbt/tools/tools/nmblookup.c)0
-rw-r--r--source4/lib/torture/torture.h4
-rw-r--r--source4/librpc/tools/ndrdump.c12
-rw-r--r--source4/torture/auth/pac.c2
-rw-r--r--source4/torture/basic/misc.c2
-rw-r--r--source4/torture/locktest.c2
-rw-r--r--source4/torture/util_smb.c2
8 files changed, 9 insertions, 17 deletions
diff --git a/lib/util/tests/file.c b/lib/util/tests/file.c
index 3377e833dc3..9a303bf8c1b 100644
--- a/lib/util/tests/file.c
+++ b/lib/util/tests/file.c
@@ -42,7 +42,7 @@ static bool test_file_load_save(struct torture_context *tctx)
torture_assert_file_contains_text(tctx, TEST_FILENAME, TEST_DATA,
"file contents");
- data = file_load(TEST_FILENAME, &len, mem_ctx);
+ data = file_load(TEST_FILENAME, &len, 0, mem_ctx);
torture_assert(tctx, data, "loading file");
torture_assert_int_equal(tctx, len, strlen(TEST_DATA), "Length");
diff --git a/libcli/nbt/tools/tools/nmblookup.c b/libcli/nbt/tools/nmblookup.c
index 0d98cb99de4..0d98cb99de4 100644
--- a/libcli/nbt/tools/tools/nmblookup.c
+++ b/libcli/nbt/tools/nmblookup.c
diff --git a/source4/lib/torture/torture.h b/source4/lib/torture/torture.h
index f023f319ffe..0f966a52d13 100644
--- a/source4/lib/torture/torture.h
+++ b/source4/lib/torture/torture.h
@@ -267,7 +267,7 @@ void torture_result(struct torture_context *test,
char *__got; \
const char *__expected = (expected); \
size_t __size; \
- __got = file_load(filename, &__size, torture_ctx); \
+ __got = file_load(filename, &__size, 0, torture_ctx); \
if (__got == NULL) { \
torture_result(torture_ctx, TORTURE_FAIL, \
__location__": unable to open %s: %s\n", \
@@ -288,7 +288,7 @@ void torture_result(struct torture_context *test,
#define torture_assert_file_contains(torture_ctx,filename,expected,cmt)\
do { const char *__got, *__expected = (expected); \
size_t __size; \
- __got = file_load(filename, *size, torture_ctx); \
+ __got = file_load(filename, *size, 0, torture_ctx); \
if (strcmp_safe(__got, __expected) != 0) { \
torture_result(torture_ctx, TORTURE_FAIL, \
__location__": %s contained:\n%sExpected: %s%s\n", \
diff --git a/source4/librpc/tools/ndrdump.c b/source4/librpc/tools/ndrdump.c
index bc1436916f6..b24868eaced 100644
--- a/source4/librpc/tools/ndrdump.c
+++ b/source4/librpc/tools/ndrdump.c
@@ -291,11 +291,7 @@ static void ndrdump_data(uint8_t *d, uint32_t l, bool force)
exit(1);
}
-#if (_SAMBA_BUILD_ >= 4)
- data = (uint8_t *)file_load(ctx_filename, &size, mem_ctx);
-#else
- data = (uint8_t *)file_load(ctx_filename, &size, 0);
-#endif
+ data = (uint8_t *)file_load(ctx_filename, &size, 0, mem_ctx);
if (!data) {
perror(ctx_filename);
exit(1);
@@ -322,11 +318,7 @@ static void ndrdump_data(uint8_t *d, uint32_t l, bool force)
}
if (filename)
-#if (_SAMBA_BUILD_ >= 4)
- data = (uint8_t *)file_load(filename, &size, mem_ctx);
-#else
- data = (uint8_t *)file_load(filename, &size, 0);
-#endif
+ data = (uint8_t *)file_load(filename, &size, 0, mem_ctx);
else
data = (uint8_t *)stdin_load(mem_ctx, &size);
diff --git a/source4/torture/auth/pac.c b/source4/torture/auth/pac.c
index 42901f1eff1..f6f2fcb4989 100644
--- a/source4/torture/auth/pac.c
+++ b/source4/torture/auth/pac.c
@@ -379,7 +379,7 @@ static bool torture_pac_saved_check(struct torture_context *tctx)
pac_file = torture_setting_string(tctx, "pac_file", NULL);
if (pac_file) {
- tmp_blob.data = (uint8_t *)file_load(pac_file, &tmp_blob.length, mem_ctx);
+ tmp_blob.data = (uint8_t *)file_load(pac_file, &tmp_blob.length, 0, mem_ctx);
torture_comment(tctx, "(saved test) Loaded pac of size %ld from %s\n", (long)tmp_blob.length, pac_file);
} else {
tmp_blob = data_blob_talloc(mem_ctx, saved_pac, sizeof(saved_pac));
diff --git a/source4/torture/basic/misc.c b/source4/torture/basic/misc.c
index c129fd586be..3a09fa74b55 100644
--- a/source4/torture/basic/misc.c
+++ b/source4/torture/basic/misc.c
@@ -448,7 +448,7 @@ static int init_benchrw_params(struct torture_context *tctx,
p = torture_setting_string(tctx, "unclist", NULL);
if (p) {
char *h, *s;
- unc_list = file_lines_load(p, &num_unc_names, NULL);
+ unc_list = file_lines_load(p, &num_unc_names, 0, NULL);
if (!unc_list || num_unc_names <= 0) {
torture_comment(tctx, "Failed to load unc names list "
"from '%s'\n", p);
diff --git a/source4/torture/locktest.c b/source4/torture/locktest.c
index a511e261cb9..69b966b31bb 100644
--- a/source4/torture/locktest.c
+++ b/source4/torture/locktest.c
@@ -137,7 +137,7 @@ static struct smbcli_state *connect_one(struct event_context *ev,
p = lp_parm_string(lp_ctx, NULL, "torture", "unclist");
if (p) {
char *h, *s;
- unc_list = file_lines_load(p, &num_unc_names, NULL);
+ unc_list = file_lines_load(p, &num_unc_names, 0, NULL);
if (!unc_list || num_unc_names <= 0) {
printf("Failed to load unc names list from '%s'\n", p);
exit(1);
diff --git a/source4/torture/util_smb.c b/source4/torture/util_smb.c
index 22fdfec62b6..3d9c5e321d5 100644
--- a/source4/torture/util_smb.c
+++ b/source4/torture/util_smb.c
@@ -514,7 +514,7 @@ _PUBLIC_ bool torture_get_conn_index(int conn_index,
return true;
}
- unc_list = file_lines_load(p, &num_unc_names, NULL);
+ unc_list = file_lines_load(p, &num_unc_names, 0, NULL);
if (!unc_list || num_unc_names <= 0) {
DEBUG(0,("Failed to load unc names list from '%s'\n", p));
return false;