From: Tim Beale Date: Wed, 26 Sep 2018 21:53:24 +0000 (+1200) Subject: libcli: Add debug message if fail to negoatiate SMB protocol X-Git-Tag: tdb-1.3.17~1477 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=34cbd89fec836f5de0cb5ba3f289b1f4ae00c5d7;p=thirdparty%2Fsamba.git libcli: Add debug message if fail to negoatiate SMB protocol Currently if the client and server can't negotiate an SMB protocol, you just get the followiing error on the client-side, which doesn't tell you much. ERROR(runtime): uncaught exception - (3221225667, 'The network responded incorrectly.') This patch adds a debug message to help highlight what's actually going wrong. BUG: https://bugzilla.samba.org/show_bug.cgi?id=13621 Signed-off-by: Tim Beale Reviewed-by: Ralph Boehme Reviewed-by: Andrew Bartlett Autobuild-User(master): Andrew Bartlett Autobuild-Date(master): Fri Sep 28 11:25:29 CEST 2018 on sn-devel-144 --- diff --git a/libcli/smb/smbXcli_base.c b/libcli/smb/smbXcli_base.c index ad1b67b8476..d94b4d87f27 100644 --- a/libcli/smb/smbXcli_base.c +++ b/libcli/smb/smbXcli_base.c @@ -4369,6 +4369,7 @@ static void smbXcli_negprot_smb1_done(struct tevent_req *subreq) } if (conn->protocol == PROTOCOL_NONE) { + DBG_ERR("No compatible protocol selected by server.\n"); tevent_req_nterror(req, NT_STATUS_INVALID_NETWORK_RESPONSE); return; }