diff options
author | Jeremy Allison <jra@samba.org> | 2002-11-12 23:15:52 +0000 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2002-11-12 23:15:52 +0000 |
commit | 250c9801197ea1c949bd94c1c891f81ab118b130 (patch) | |
tree | 3a0ec79c71a010961d78726e223a70e1bc75c73f /source3/smbd/change_trust_pw.c | |
parent | 477025a6f628fd1a8d3bfacd30726e7a41819e50 (diff) | |
download | samba-250c9801197ea1c949bd94c1c891f81ab118b130.tar.gz samba-250c9801197ea1c949bd94c1c891f81ab118b130.tar.bz2 samba-250c9801197ea1c949bd94c1c891f81ab118b130.zip |
Removed global_myworkgroup, global_myname, global_myscope. Added liberal
dashes of const. This is a rather large check-in, some things may break.
It does compile though :-).
Jeremy.
(This used to be commit 82b8f749a36b42e22186297482aad2abb04fab8a)
Diffstat (limited to 'source3/smbd/change_trust_pw.c')
-rw-r--r-- | source3/smbd/change_trust_pw.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/source3/smbd/change_trust_pw.c b/source3/smbd/change_trust_pw.c index 4811083c2d..28a004eba8 100644 --- a/source3/smbd/change_trust_pw.c +++ b/source3/smbd/change_trust_pw.c @@ -24,13 +24,11 @@ #include "includes.h" -extern pstring global_myname; - /********************************************************* Change the domain password on the PDC. **********************************************************/ -static NTSTATUS modify_trust_password( char *domain, char *remote_machine, +static NTSTATUS modify_trust_password( const char *domain, const char *remote_machine, unsigned char orig_trust_passwd_hash[16]) { struct cli_state *cli; @@ -46,7 +44,7 @@ static NTSTATUS modify_trust_password( char *domain, char *remote_machine, return NT_STATUS_UNSUCCESSFUL; } - if (!NT_STATUS_IS_OK(cli_full_connection(&cli, global_myname, remote_machine, + if (!NT_STATUS_IS_OK(cli_full_connection(&cli, global_myname(), remote_machine, NULL, 0, "IPC$", "IPC", "", "", @@ -82,7 +80,7 @@ machine %s. Error was : %s.\n", remote_machine, cli_errstr(cli))); Change the trust account password for a domain. ************************************************************************/ -NTSTATUS change_trust_account_password( char *domain, char *remote_machine_list) +NTSTATUS change_trust_account_password( const char *domain, const char *remote_machine_list) { fstring remote_machine; unsigned char old_trust_passwd_hash[16]; @@ -117,7 +115,7 @@ account password for domain %s.\n", domain)); * address used as a string. */ - if(!lookup_dc_name(global_myname, domain, &pdc_ip, dc_name)) + if(!lookup_dc_name(global_myname(), domain, &pdc_ip, dc_name)) continue; if(NT_STATUS_IS_OK(res = modify_trust_password( domain, dc_name, old_trust_passwd_hash))) |