summaryrefslogtreecommitdiff
path: root/source3/libsmb/cli_lsarpc.c
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2001-09-04 07:13:01 +0000
committerAndrew Tridgell <tridge@samba.org>2001-09-04 07:13:01 +0000
commit19fea3242cf6234786b6cbb60631e0071f31ff9f (patch)
tree1de6e79890a80a1e03cf0dce5813513aaf51bc59 /source3/libsmb/cli_lsarpc.c
parent55cf37488f66eba2826dba08e80dd4ab6df33fc3 (diff)
downloadsamba-19fea3242cf6234786b6cbb60631e0071f31ff9f.tar.gz
samba-19fea3242cf6234786b6cbb60631e0071f31ff9f.tar.bz2
samba-19fea3242cf6234786b6cbb60631e0071f31ff9f.zip
the next stage in the NTSTATUS/WERROR change. smbd and nmbd now compile, but the client code still needs some work
(This used to be commit dcd6e735f709a9231860ceb9682db40ff26c9a66)
Diffstat (limited to 'source3/libsmb/cli_lsarpc.c')
-rw-r--r--source3/libsmb/cli_lsarpc.c21
1 files changed, 11 insertions, 10 deletions
diff --git a/source3/libsmb/cli_lsarpc.c b/source3/libsmb/cli_lsarpc.c
index 791b6eace3..f2fc167606 100644
--- a/source3/libsmb/cli_lsarpc.c
+++ b/source3/libsmb/cli_lsarpc.c
@@ -78,7 +78,7 @@ NTSTATUS cli_lsa_open_policy(struct cli_state *cli, TALLOC_CTX *mem_ctx,
/* Return output parameters */
- if ((result = r.status) == NT_STATUS_OK) {
+ if (NT_STATUS_IS_OK(result = r.status)) {
*pol = r.pol;
}
@@ -136,7 +136,7 @@ NTSTATUS cli_lsa_open_policy2(struct cli_state *cli, TALLOC_CTX *mem_ctx,
/* Return output parameters */
- if ((result = r.status) == NT_STATUS_OK) {
+ if (NT_STATUS_IS_OK(result = r.status)) {
*pol = r.pol;
}
@@ -184,7 +184,7 @@ NTSTATUS cli_lsa_close(struct cli_state *cli, TALLOC_CTX *mem_ctx,
/* Return output parameters */
- if ((result = r.status) == NT_STATUS_OK) {
+ if (NT_STATUS_IS_OK(result = r.status)) {
*pol = r.pol;
}
@@ -242,8 +242,9 @@ NTSTATUS cli_lsa_lookup_sids(struct cli_state *cli, TALLOC_CTX *mem_ctx,
result = r.status;
- if (result != NT_STATUS_OK && result != 0x00000107 &&
- result != (0xC0000000 | NT_STATUS_NONE_MAPPED)) {
+ if (!NT_STATUS_IS_OK(result) &&
+ NT_STATUS_V(result) != NT_STATUS_V(NT_STATUS_FILES_OPEN) &&
+ NT_STATUS_V(result) != NT_STATUS_V(NT_STATUS_NONE_MAPPED)) {
/* An actual error occured */
@@ -347,8 +348,8 @@ NTSTATUS cli_lsa_lookup_names(struct cli_state *cli, TALLOC_CTX *mem_ctx,
result = r.status;
- if (result != NT_STATUS_OK &&
- result != (0xC0000000 | NT_STATUS_NONE_MAPPED)) {
+ if (!NT_STATUS_IS_OK(result) &&
+ NT_STATUS_V(result) != NT_STATUS_V(NT_STATUS_NONE_MAPPED)) {
/* An actual error occured */
@@ -441,7 +442,7 @@ NTSTATUS cli_lsa_query_info_policy(struct cli_state *cli, TALLOC_CTX *mem_ctx,
goto done;
}
- if ((result = r.status) != NT_STATUS_OK) {
+ if (!NT_STATUS_IS_OK(result = r.status)) {
goto done;
}
@@ -536,8 +537,8 @@ NTSTATUS cli_lsa_enum_trust_dom(struct cli_state *cli, TALLOC_CTX *mem_ctx,
0x8000001a (NT_STATUS_UNABLE_TO_FREE_VM) so we ignore it and
pretend everything is OK. */
- if (result != NT_STATUS_OK &&
- result != NT_STATUS_UNABLE_TO_FREE_VM) {
+ if (!NT_STATUS_IS_OK(result) &&
+ NT_STATUS_V(result) != NT_STATUS_V(NT_STATUS_UNABLE_TO_FREE_VM)) {
/* An actual error ocured */