Check for winbind separator in user name for cli_session_setup()
authorTim Potter <tpot@samba.org>
Sun, 6 Jan 2002 04:03:26 +0000 (04:03 +0000)
committerTim Potter <tpot@samba.org>
Sun, 6 Jan 2002 04:03:26 +0000 (04:03 +0000)
Patch from Alexander Bokovoy <a.bokovoy@sam-solutions.net>
(This used to be commit 6c42bf208976ed3020e57efff6281f984d9fe893)

source3/libsmb/cliconnect.c

index bd79f23213a2e7d2f7647d789d8adcd66d7f697e..a3b22485cf7e744a7fde6d9effb40996ef91caab 100644 (file)
@@ -576,7 +576,8 @@ BOOL cli_session_setup(struct cli_state *cli,
 
        /* allow for workgroups as part of the username */
        fstrcpy(user2, user);
-       if ((p=strchr_m(user2,'\\')) || (p=strchr_m(user2,'/'))) {
+       if ((p=strchr_m(user2,'\\')) || (p=strchr_m(user2,'/')) ||
+           (p=strchr_m(user2,*lp_winbind_separator()))) {
                *p = 0;
                user = p+1;
                workgroup = user2;