diff options
author | Michael Adam <obnox@samba.org> | 2008-01-09 01:17:13 +0100 |
---|---|---|
committer | Michael Adam <obnox@samba.org> | 2008-01-09 01:47:10 +0100 |
commit | 22068a0c167b27cf1d74a32ac516df25dce0f70a (patch) | |
tree | acf4389934f164447d5d8c9db1b33db2c9a1b268 /source3/libnet | |
parent | f269ed866d01b9924264941268d902b893fbac83 (diff) | |
download | samba-22068a0c167b27cf1d74a32ac516df25dce0f70a.tar.gz samba-22068a0c167b27cf1d74a32ac516df25dce0f70a.tar.bz2 samba-22068a0c167b27cf1d74a32ac516df25dce0f70a.zip |
Change registry_create_admin_token() to return NTSTATUS.
Michael
(This used to be commit 9cd30fb25c42e79946b5140994d0bf2ef4c62f90)
Diffstat (limited to 'source3/libnet')
-rw-r--r-- | source3/libnet/libnet_conf.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/source3/libnet/libnet_conf.c b/source3/libnet/libnet_conf.c index c8e55a70b2..d0ef6eb0e6 100644 --- a/source3/libnet/libnet_conf.c +++ b/source3/libnet/libnet_conf.c @@ -87,7 +87,7 @@ static WERROR libnet_conf_reg_open_path(TALLOC_CTX *mem_ctx, struct registry_key **key) { WERROR werr = WERR_OK; - NT_USER_TOKEN *token; + NT_USER_TOKEN *token = NULL; TALLOC_CTX *tmp_ctx = NULL; if (path == NULL) { @@ -109,11 +109,9 @@ static WERROR libnet_conf_reg_open_path(TALLOC_CTX *mem_ctx, goto done; } - token = registry_create_admin_token(tmp_ctx); - if (token == NULL) { + werr = ntstatus_to_werror(registry_create_admin_token(tmp_ctx, &token)); + if (W_ERROR_IS_OK(werr)) { DEBUG(1, ("Error creating admin token\n")); - /* what is the appropriate error code here? */ - werr = WERR_CAN_NOT_COMPLETE; goto done; } |