summaryrefslogtreecommitdiff
path: root/source4/lib
diff options
context:
space:
mode:
Diffstat (limited to 'source4/lib')
-rw-r--r--source4/lib/registry/local.c2
-rw-r--r--source4/lib/registry/samba.c2
-rw-r--r--source4/lib/registry/tests/registry.c2
3 files changed, 3 insertions, 3 deletions
diff --git a/source4/lib/registry/local.c b/source4/lib/registry/local.c
index fa59f25596..3e463100c9 100644
--- a/source4/lib/registry/local.c
+++ b/source4/lib/registry/local.c
@@ -140,7 +140,7 @@ WERROR local_get_predefined_key(struct registry_context *ctx,
}
if (mp == NULL)
- return WERR_NOT_FOUND;
+ return WERR_BADFILE;
*key = reg_import_hive_key(ctx, mp->key,
mp->path.predefined_key,
diff --git a/source4/lib/registry/samba.c b/source4/lib/registry/samba.c
index 02f3363bab..599385e73c 100644
--- a/source4/lib/registry/samba.c
+++ b/source4/lib/registry/samba.c
@@ -42,7 +42,7 @@ static WERROR mount_samba_hive(struct registry_context *ctx,
error = reg_open_hive(ctx, location, auth_info, creds, lp_ctx, &hive);
- if (W_ERROR_EQUAL(error, WERR_NOT_FOUND))
+ if (W_ERROR_EQUAL(error, WERR_BADFILE))
error = reg_open_ldb_file(ctx, location, auth_info,
creds, lp_ctx, &hive);
diff --git a/source4/lib/registry/tests/registry.c b/source4/lib/registry/tests/registry.c
index 59e31f55dc..06783e6a75 100644
--- a/source4/lib/registry/tests/registry.c
+++ b/source4/lib/registry/tests/registry.c
@@ -53,7 +53,7 @@ static bool test_get_predefined_unknown(struct torture_context *tctx,
WERROR error;
error = reg_get_predefined_key(rctx, 1337, &root);
- torture_assert_werr_equal(tctx, error, WERR_NOT_FOUND,
+ torture_assert_werr_equal(tctx, error, WERR_BADFILE,
"getting predefined key failed");
return true;
}