From: Ralph Boehme Date: Fri, 24 Nov 2023 15:29:57 +0000 (+0100) Subject: smbd: leave comment on broken SMB1 POSIX open handling of SMB_O_DIRECT X-Git-Tag: talloc-2.4.2~538 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=3f73bb591cf0ab4e7e305c9b58727790e54b32ed;p=thirdparty%2Fsamba.git smbd: leave comment on broken SMB1 POSIX open handling of SMB_O_DIRECT Since e0814dc5082dd4ecca8a155e0ce24b073158fd92 the passed in attributes get replaced by the mode in create_file_default(). As FILE_FLAG_NO_BUFFERING is never checked when doing the final IO, it doesn't really matter. Signed-off-by: Ralph Boehme Reviewed-by: Jeremy Allison --- diff --git a/source3/smbd/smb1_trans2.c b/source3/smbd/smb1_trans2.c index 77a5d361649..b2a6cf88b24 100644 --- a/source3/smbd/smb1_trans2.c +++ b/source3/smbd/smb1_trans2.c @@ -3461,6 +3461,12 @@ static NTSTATUS smb_posix_open(connection_struct *conn, access_mask |= FILE_APPEND_DATA; } if (wire_open_mode & SMB_O_DIRECT) { + /* + * BUG: this doesn't work anymore since + * e0814dc5082dd4ecca8a155e0ce24b073158fd92. But since + * FILE_FLAG_NO_BUFFERING isn't used at all in the IO codepath, + * it doesn't really matter. + */ attributes |= FILE_FLAG_NO_BUFFERING; }