Fix bug 6829 - smbclient does not show special characters properly. All successful...
authorJeremy Allison <jra@samba.org>
Thu, 22 Oct 2009 22:30:47 +0000 (15:30 -0700)
committerKarolin Seeger <kseeger@samba.org>
Mon, 26 Oct 2009 10:52:33 +0000 (11:52 +0100)
commit00c42f0981a10144dc78b86336f5d5177780a4bd
treebbc427e4f337cf721ac0f32e60fa1f01236518f1
parent6cbf9e806644021aef4ad0d1d97c97e1e972e18e
Fix bug 6829 - smbclient does not show special characters properly. All successful calls to cli_session_setup() *must* be followed by calls to cli_init_creds() to stash the credentials we successfully connected with. There were 2 codepaths where this was missing. This caused smbclient to be unable to open the \srvsvc pipe to do an RPC netserverenum, and cause it to fall back to a RAP netserverenum, which uses DOS codepage conversion rather than the full UCS2 of RPC, so the returned characters were not correct (unless the DOS codepage was set correctly). Phew. That was fun to track down :-). Includes logic simplification in libsmb_server.c Jeremy.
(cherry picked from commit 587ca743bf1491e97c984ce4bec5a9bd0a1ae69a)
source3/libsmb/clidfs.c
source3/libsmb/libsmb_server.c