[SCM] Samba Shared Repository - branch v3-2-test updated -
release-3-2-0pre2-626-gea3cfad
Günther Deschner
gd at samba.org
Wed Apr 2 22:27:59 GMT 2008
The branch, v3-2-test has been updated
via ea3cfadc2504c891b4784719bd8e6debcc38c879 (commit)
via 9e15ce03ca66a0b5ffdb39dd2faaad6e0f967e31 (commit)
from f6069126e5e6d239b1ae00e897a420227f923e3f (commit)
http://gitweb.samba.org/?p=samba.git;a=shortlog;h=v3-2-test
- Log -----------------------------------------------------------------
commit ea3cfadc2504c891b4784719bd8e6debcc38c879
Author: Günther Deschner <gd at samba.org>
Date: Thu Apr 3 00:23:50 2008 +0200
Fix rpccli_lsa_lookup_sids_noalloc.
When looking up e.g. a trusted doamin account, there is just no name.
Michael, please check.
Guenther
commit 9e15ce03ca66a0b5ffdb39dd2faaad6e0f967e31
Author: Günther Deschner <gd at samba.org>
Date: Wed Apr 2 15:26:27 2008 +0200
Add NT_STATUS_RPC_CANNOT_SUPPORT.
Guenther
-----------------------------------------------------------------------
Summary of changes:
source/include/nterr.h | 1 +
source/libsmb/nterr.c | 1 +
source/rpc_client/cli_lsarpc.c | 14 +++++++++++---
3 files changed, 13 insertions(+), 3 deletions(-)
Changeset truncated at 500 lines:
diff --git a/source/include/nterr.h b/source/include/nterr.h
index 5749c4e..612cf6e 100644
--- a/source/include/nterr.h
+++ b/source/include/nterr.h
@@ -566,5 +566,6 @@
#define NT_STATUS_DOWNGRADE_DETECTED NT_STATUS(0xC0000000 | 0x0388)
#define NT_STATUS_NO_SUCH_JOB NT_STATUS(0xC0000000 | 0xEDE) /* scheduler */
#define NT_STATUS_RPC_PROTSEQ_NOT_SUPPORTED NT_STATUS(0xC0000000 | 0x20004)
+#define NT_STATUS_RPC_CANNOT_SUPPORT NT_STATUS(0xC0000000 | 0x20041)
#endif /* _NTERR_H */
diff --git a/source/libsmb/nterr.c b/source/libsmb/nterr.c
index 608fe9d..fc63403 100644
--- a/source/libsmb/nterr.c
+++ b/source/libsmb/nterr.c
@@ -539,6 +539,7 @@ static const nt_err_code_struct nt_errs[] =
{ "STATUS_MORE_ENTRIES", STATUS_MORE_ENTRIES },
{ "STATUS_SOME_UNMAPPED", STATUS_SOME_UNMAPPED },
{ "STATUS_NO_MORE_FILES", STATUS_NO_MORE_FILES },
+ { "NT_STATUS_RPC_CANNOT_SUPPORT", NT_STATUS_RPC_CANNOT_SUPPORT },
{ NULL, NT_STATUS(0) }
};
diff --git a/source/rpc_client/cli_lsarpc.c b/source/rpc_client/cli_lsarpc.c
index 3d57e22..37387a0 100644
--- a/source/rpc_client/cli_lsarpc.c
+++ b/source/rpc_client/cli_lsarpc.c
@@ -203,11 +203,19 @@ static NTSTATUS rpccli_lsa_lookup_sids_noalloc(struct rpc_pipe_client *cli,
dom_name = ref_domains->domains[dom_idx].name.string;
name = lsa_names.names[i].name.string;
- (names)[i] = talloc_strdup(mem_ctx, name);
+ if (name) {
+ (names)[i] = talloc_strdup(mem_ctx, name);
+ if ((names)[i] == NULL) {
+ DEBUG(0, ("cli_lsa_lookup_sids_noalloc(): out of memory\n"));
+ result = NT_STATUS_UNSUCCESSFUL;
+ goto done;
+ }
+ } else {
+ (names)[i] = NULL;
+ }
(domains)[i] = talloc_strdup(mem_ctx, dom_name);
(types)[i] = lsa_names.names[i].sid_type;
-
- if (((names)[i] == NULL) || ((domains)[i] == NULL)) {
+ if (((domains)[i] == NULL)) {
DEBUG(0, ("cli_lsa_lookup_sids_noalloc(): out of memory\n"));
result = NT_STATUS_UNSUCCESSFUL;
goto done;
--
Samba Shared Repository
More information about the samba-cvs
mailing list