diff options
Diffstat (limited to 'source3/smbd/oplock.c')
-rw-r--r-- | source3/smbd/oplock.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/source3/smbd/oplock.c b/source3/smbd/oplock.c index 2c3313606a..8a5b1f4ecd 100644 --- a/source3/smbd/oplock.c +++ b/source3/smbd/oplock.c @@ -252,11 +252,13 @@ static char *new_break_smb_message(TALLOC_CTX *mem_ctx, } memset(result,'\0',smb_size); - /* We use cli_set_message here as this is an - * asynchronous message that doesn't belong in - * the stream. - */ - cli_set_message(result,8,0,True); + if (!srv_encryption_on()) { + cli_set_message(result,8,0,true); + } else { + char inbuf[8]; + smb_set_enclen(inbuf,4,srv_enc_ctx()); + srv_set_message(inbuf,result,8,0,true); + } SCVAL(result,smb_com,SMBlockingX); SSVAL(result,smb_tid,fsp->conn->cnum); SSVAL(result,smb_pid,0xFFFF); |