smbd:smb2: add a modify flag to dispatch table
authorMichael Adam <obnox@samba.org>
Wed, 24 Feb 2016 14:51:14 +0000 (15:51 +0100)
committerJeremy Allison <jra@samba.org>
Mon, 21 Mar 2016 23:23:21 +0000 (00:23 +0100)
This indicates that an operation is a modifying operation.
Some parts of the upcoming channel sequence number logic
only applies to modify operations.

Pair-Programmed-With: Stefan Metzmacher <metze@samba.org>

Signed-off-by: Michael Adam <obnox@samba.org>
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
source3/smbd/smb2_server.c

index 68d637e0c23596fa4e13aa0703d68e957eb5c2c9..7b6d8d64099201eb49c2ce93663fdfdd73b6688e 100644 (file)
@@ -46,6 +46,7 @@ static const struct smbd_smb2_dispatch_table {
        bool as_root;
        uint16_t fileid_ofs;
        bool allow_invalid_fileid;
+       bool modify;
 } smbd_smb2_table[] = {
 #define _OP(o) .opcode = o, .name = #o
        {
@@ -98,6 +99,7 @@ static const struct smbd_smb2_dispatch_table {
                .need_session = true,
                .need_tcon = true,
                .fileid_ofs = 0x10,
+               .modify = true,
        },{
                _OP(SMB2_OP_LOCK),
                .need_session = true,
@@ -109,6 +111,7 @@ static const struct smbd_smb2_dispatch_table {
                .need_tcon = true,
                .fileid_ofs = 0x08,
                .allow_invalid_fileid = true,
+               .modify = true,
        },{
                _OP(SMB2_OP_CANCEL),
                .as_root = true,
@@ -135,6 +138,7 @@ static const struct smbd_smb2_dispatch_table {
                .need_session = true,
                .need_tcon = true,
                .fileid_ofs = 0x10,
+               .modify = true,
        },{
                _OP(SMB2_OP_BREAK),
                .need_session = true,