can_add_account = FALSE, why do we attempt to add anyway?

Brad Langhorst brad at
Fri Jul 22 16:51:45 GMT 2005

in srv_samr_nt.c at line 2315 we have this code...

      if ( can_add_account )

        if ( !pw ) {
                if (*add_script) {
                        int add_ret;

                        all_string_sub(add_script, "%u", account,
                        add_ret = smbrun(add_script,NULL);
                        DEBUG(add_ret ? 0 : 3,("_samr_create_user:
Running the command `%s' gave %d\n", add_script, add_\ret));
                else    /* no add user script -- ask winbindd to do it

If can_add_account is false then why do we try to add the account?

Seems like this should print an error message instead of attempting to
do the add anyway.

Now to figure out why can_add_account is being set to false for


More information about the samba-technical mailing list