mirror of
https://github.com/samba-team/samba.git
synced 2025-08-02 00:22:11 +03:00
Changes from APPLIANCE_HEAD:
source/lib/smbpasswd.c - Only call load_interfaces() when doing a network related operation. This means you can add, remove, enable or disable smbpasswd entries without a network. Changing passwords always requires a network.
This commit is contained in:
@ -327,6 +327,12 @@ static int process_root(int argc, char *argv[])
|
||||
usage();
|
||||
}
|
||||
|
||||
/* Only load interfaces if we are doing network operations. */
|
||||
|
||||
if (joining_domain || remote_machine) {
|
||||
load_interfaces();
|
||||
}
|
||||
|
||||
if(joining_domain) {
|
||||
if (argc != 0)
|
||||
usage();
|
||||
@ -506,11 +512,13 @@ static int process_nonroot(int argc, char *argv[])
|
||||
* via a remote machine (even if that machine is
|
||||
* localhost).
|
||||
*/
|
||||
|
||||
load_interfaces(); /* Delayed from main() */
|
||||
|
||||
if (remote_machine == NULL) {
|
||||
remote_machine = "127.0.0.1";
|
||||
}
|
||||
|
||||
|
||||
if (remote_machine != NULL) {
|
||||
old_passwd = get_pass("Old SMB password:",stdin_passwd_get);
|
||||
}
|
||||
@ -585,7 +593,6 @@ int main(int argc, char **argv)
|
||||
|
||||
codepage_initialise(lp_client_code_page());
|
||||
|
||||
load_interfaces();
|
||||
secrets_init();
|
||||
|
||||
/* Check the effective uid - make sure we are not setuid */
|
||||
|
Reference in New Issue
Block a user