diff --git a/source3/client/client.c b/source3/client/client.c index 8f449e81311..754907d2e09 100644 --- a/source3/client/client.c +++ b/source3/client/client.c @@ -6027,7 +6027,13 @@ static void readline_callback(void) /* Ping the server to keep the connection alive using SMBecho. */ memset(garbage, 0xf0, sizeof(garbage)); status = cli_echo(cli, 1, data_blob_const(garbage, sizeof(garbage))); - if (NT_STATUS_IS_OK(status)) { + if (NT_STATUS_IS_OK(status) || + NT_STATUS_EQUAL(status, NT_STATUS_INVALID_PARAMETER)) { + /* + * Even if server returns NT_STATUS_INVALID_PARAMETER + * it still responded. + * BUG: https://bugzilla.samba.org/show_bug.cgi?id=13007 + */ return; } diff --git a/source3/libsmb/libsmb_server.c b/source3/libsmb/libsmb_server.c index 93b9e800910..e6067be2013 100644 --- a/source3/libsmb/libsmb_server.c +++ b/source3/libsmb/libsmb_server.c @@ -61,7 +61,16 @@ SMBC_check_server(SMBCCTX * context, 1, data_blob_const(data, sizeof(data))); if (!NT_STATUS_IS_OK(status)) { - return 1; + /* + * Some NetApp servers return + * NT_STATUS_INVALID_PARAMETER.That's OK, they still + * replied. + * BUG: https://bugzilla.samba.org/show_bug.cgi?id=13007 + */ + if (!NT_STATUS_EQUAL(status, + NT_STATUS_INVALID_PARAMETER)) { + return 1; + } } server->last_echo_time = now; }