diff options
author | Gerald Carter <jerry@samba.org> | 2004-01-13 17:55:43 +0000 |
---|---|---|
committer | Gerald Carter <jerry@samba.org> | 2004-01-13 17:55:43 +0000 |
commit | 0c9adb69858c7572320d18c0fd187dd6e885f17d (patch) | |
tree | d58b1ad6bbc5ca0e9f71d17ebdaa9905268fa1d4 /source3/rpcclient | |
parent | 60079bd15bee7fe71dd43cb131f6198ca28f74eb (diff) | |
download | samba-0c9adb69858c7572320d18c0fd187dd6e885f17d.tar.gz samba-0c9adb69858c7572320d18c0fd187dd6e885f17d.tar.bz2 samba-0c9adb69858c7572320d18c0fd187dd6e885f17d.zip |
sync HEAD with recent changes in 3.0
(This used to be commit c98399e3c9d74e19b7c9d806ca8028b48866931e)
Diffstat (limited to 'source3/rpcclient')
-rw-r--r-- | source3/rpcclient/cmd_lsarpc.c | 30 | ||||
-rw-r--r-- | source3/rpcclient/cmd_spoolss.c | 2 |
2 files changed, 18 insertions, 14 deletions
diff --git a/source3/rpcclient/cmd_lsarpc.c b/source3/rpcclient/cmd_lsarpc.c index 217e6b1d68..d9afde465d 100644 --- a/source3/rpcclient/cmd_lsarpc.c +++ b/source3/rpcclient/cmd_lsarpc.c @@ -68,9 +68,13 @@ static NTSTATUS cmd_lsa_query_info_policy(struct cli_state *cli, { POLICY_HND pol; NTSTATUS result = NT_STATUS_UNSUCCESSFUL; - DOM_SID dom_sid; - struct uuid dom_guid; - fstring sid_str, domain_name="", dns_name="", forest_name=""; + DOM_SID *dom_sid; + struct uuid *dom_guid; + fstring sid_str; + char *domain_name = NULL; + char *dns_name = NULL; + char *forest_name = NULL; + uint32 info_class = 3; if (argc > 2) { @@ -91,8 +95,8 @@ static NTSTATUS cmd_lsa_query_info_policy(struct cli_state *cli, if (!NT_STATUS_IS_OK(result)) goto done; result = cli_lsa_query_info_policy2(cli, mem_ctx, &pol, - info_class, domain_name, - dns_name, forest_name, + info_class, &domain_name, + &dns_name, &forest_name, &dom_guid, &dom_sid); break; default: @@ -103,28 +107,28 @@ static NTSTATUS cmd_lsa_query_info_policy(struct cli_state *cli, if (!NT_STATUS_IS_OK(result)) goto done; result = cli_lsa_query_info_policy(cli, mem_ctx, &pol, - info_class, domain_name, + info_class, &domain_name, &dom_sid); } if (!NT_STATUS_IS_OK(result)) goto done; + + sid_to_string(sid_str, dom_sid); - sid_to_string(sid_str, &dom_sid); - - if (domain_name[0]) + if (domain_name) printf("domain %s has sid %s\n", domain_name, sid_str); else printf("could not query info for level %d\n", info_class); - if (dns_name[0]) + if (dns_name) printf("domain dns name is %s\n", dns_name); - if (forest_name[0]) + if (forest_name) printf("forest name is %s\n", forest_name); if (info_class == 12) { - printf("domain GUID is %s\n", - smb_uuid_string_static(dom_guid)); + printf("domain GUID is "); + smb_uuid_string_static(*dom_guid); } done: return result; diff --git a/source3/rpcclient/cmd_spoolss.c b/source3/rpcclient/cmd_spoolss.c index 798949fae9..f5a440c024 100644 --- a/source3/rpcclient/cmd_spoolss.c +++ b/source3/rpcclient/cmd_spoolss.c @@ -1336,7 +1336,7 @@ static WERROR cmd_spoolss_addprinterex(struct cli_state *cli, slprintf(servername, sizeof(servername)-1, "\\\\%s", cli->desthost); strupper_m(servername); - /* Fill in the DRIVER_INFO_3 struct */ + /* Fill in the DRIVER_INFO_2 struct */ ZERO_STRUCT(info2); #if 0 /* JERRY */ init_unistr( &info2.servername, servername); |