From 82379c7bd1827601630da120f5b5ebb9061ce2b5 Mon Sep 17 00:00:00 2001 From: Gerald Carter Date: Thu, 10 Mar 2005 20:14:24 +0000 Subject: r5729: partial fixes for BUG 2308; libsmbclient patches from Derrell Lipman (This used to be commit 88678bc05c3018eb181f97523a0b84b60e3c358d) --- source3/libsmb/cliconnect.c | 7 ++++++- source3/libsmb/clientgen.c | 1 + 2 files changed, 7 insertions(+), 1 deletion(-) (limited to 'source3') diff --git a/source3/libsmb/cliconnect.c b/source3/libsmb/cliconnect.c index 01a92a89ba..aa37a29391 100644 --- a/source3/libsmb/cliconnect.c +++ b/source3/libsmb/cliconnect.c @@ -888,7 +888,12 @@ BOOL cli_ulogoff(struct cli_state *cli) if (!cli_receive_smb(cli)) return False; - return !cli_is_error(cli); + if (cli_is_error(cli)) { + return False; + } + + cli->cnum = -1; + return True; } /**************************************************************************** diff --git a/source3/libsmb/clientgen.c b/source3/libsmb/clientgen.c index 369fba3521..b7bc780a1a 100644 --- a/source3/libsmb/clientgen.c +++ b/source3/libsmb/clientgen.c @@ -282,6 +282,7 @@ struct cli_state *cli_initialise(struct cli_state *cli) cli->inbuf = (char *)SMB_MALLOC(cli->bufsize+SAFETY_MARGIN); cli->oplock_handler = cli_oplock_ack; cli->case_sensitive = False; + cli->smb_rw_error = 0; cli->use_spnego = lp_client_use_spnego(); -- cgit