diff options
author | Volker Lendecke <vl@samba.org> | 2008-10-05 13:58:09 +0200 |
---|---|---|
committer | Volker Lendecke <vl@samba.org> | 2008-10-05 14:02:34 +0200 |
commit | 8670235f2a2b9ef4b6863c185bd2ab57acd7e57a (patch) | |
tree | 0552df8080a5f4bb445bbca9363744668a4d534b /source3/lib | |
parent | 01ecd766c86ad49c7d8b9095bef76b5dcc71d757 (diff) | |
download | samba-8670235f2a2b9ef4b6863c185bd2ab57acd7e57a.tar.gz samba-8670235f2a2b9ef4b6863c185bd2ab57acd7e57a.tar.bz2 samba-8670235f2a2b9ef4b6863c185bd2ab57acd7e57a.zip |
Fix some missing error handlings
Diffstat (limited to 'source3/lib')
-rw-r--r-- | source3/lib/netapi/file.c | 3 | ||||
-rw-r--r-- | source3/lib/netapi/getdc.c | 4 | ||||
-rw-r--r-- | source3/lib/netapi/share.c | 3 |
3 files changed, 8 insertions, 2 deletions
diff --git a/source3/lib/netapi/file.c b/source3/lib/netapi/file.c index 036af32f38..0d66be0eb1 100644 --- a/source3/lib/netapi/file.c +++ b/source3/lib/netapi/file.c @@ -47,7 +47,8 @@ WERROR NetFileClose_r(struct libnetapi_ctx *ctx, r->in.server_name, r->in.fileid, &werr); - if (!W_ERROR_IS_OK(werr)) { + if (!NT_STATUS_IS_OK(status)) { + werr = ntstatus_to_werror(status); goto done; } diff --git a/source3/lib/netapi/getdc.c b/source3/lib/netapi/getdc.c index 07a6544af1..76c0d0be2a 100644 --- a/source3/lib/netapi/getdc.c +++ b/source3/lib/netapi/getdc.c @@ -58,6 +58,10 @@ WERROR NetGetDCName_r(struct libnetapi_ctx *ctx, r->in.domain_name, (const char **)r->out.buffer, &werr); + + if (!NT_STATUS_IS_OK(status)) { + werr = ntstatus_to_werror(status); + } done: return werr; diff --git a/source3/lib/netapi/share.c b/source3/lib/netapi/share.c index 1d0e1810f1..e6aed36064 100644 --- a/source3/lib/netapi/share.c +++ b/source3/lib/netapi/share.c @@ -271,7 +271,8 @@ WERROR NetShareDel_r(struct libnetapi_ctx *ctx, r->in.net_name, r->in.reserved, &werr); - if (!W_ERROR_IS_OK(werr)) { + if (!NT_STATUS_IS_OK(status)) { + werr = ntstatus_to_werror(status); goto done; } |