From: Bo Yang Date: Fri, 7 Aug 2009 06:58:36 +0000 (+0800) Subject: s3: Unable to browse DFS when using kerberos in libsmbclient X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=40da23b6a7dc7acfbdf76a6808b7e50c6c39093e;p=thirdparty%2Fsamba.git s3: Unable to browse DFS when using kerberos in libsmbclient Signed-off-by: Bo Yang Fixes bug #6615. --- diff --git a/source/libsmb/libsmb_context.c b/source/libsmb/libsmb_context.c index ec163114126..8e0aa1e3c99 100644 --- a/source/libsmb/libsmb_context.c +++ b/source/libsmb/libsmb_context.c @@ -655,14 +655,23 @@ void smbc_set_credentials_with_fallback(SMBCCTX *context, smbc_bool use_kerberos = false; const char *signing_state = "off"; - if (!context || - ! workgroup || ! *workgroup || - ! user || ! *user || - ! password || ! *password) { + if (! context) { return; } + if (! workgroup || ! *workgroup) { + workgroup = smbc_getWorkgroup(context); + } + + if (! user) { + user = smbc_getUser(context); + } + + if (! password) { + password = ""; + } + if (smbc_getOptionUseKerberos(context)) { use_kerberos = True; }