From 6bc6a5cdc83fd780767fef2c89369a4079e621d9 Mon Sep 17 00:00:00 2001 From: Stefan Metzmacher Date: Tue, 31 Jan 2012 10:02:18 -0800 Subject: [PATCH] s3:client: ignore SMBecho errors (the server may not support it) (bug #8139) Signed-off-by: Jeremy Allison --- source3/client/client.c | 10 +++++++--- 1 files changed, 7 insertions(+), 3 deletions(-) diff --git a/source3/client/client.c b/source3/client/client.c index b2cb911..05c4f91 100644 --- a/source3/client/client.c +++ b/source3/client/client.c @@ -4844,9 +4844,13 @@ static void readline_callback(void) memset(garbage, 0xf0, sizeof(garbage)); status = cli_echo(cli, 1, data_blob_const(garbage, sizeof(garbage))); - if (!NT_STATUS_IS_OK(status)) { - DEBUG(0, ("SMBecho failed. Maybe server has closed " - "the connection\n")); + if (NT_STATUS_IS_OK(status)) { + return; + } + + if (!cli_state_is_connected(cli)) { + DEBUG(0, ("SMBecho failed (%s). The connection is " + "disconnected now\n", nt_errstr(status))); finished = true; smb_readline_done(); } -- 1.7.7.3