summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--source4/include/smb.h5
-rw-r--r--source4/torture/nbench/nbio.c5
2 files changed, 8 insertions, 2 deletions
diff --git a/source4/include/smb.h b/source4/include/smb.h
index 9486890385..04b3c5b633 100644
--- a/source4/include/smb.h
+++ b/source4/include/smb.h
@@ -551,6 +551,11 @@
#define BATCH_OPLOCK_RETURN 2
#define LEVEL_II_OPLOCK_RETURN 3
+/* oplock levels sent in oplock break */
+#define OPLOCK_BREAK_TO_NONE 0
+#define OPLOCK_BREAK_TO_LEVEL_II 1
+
+
#define CMD_REPLY 0x8000
/* The maximum length of a trust account password.
diff --git a/source4/torture/nbench/nbio.c b/source4/torture/nbench/nbio.c
index ce408bba93..96d763651e 100644
--- a/source4/torture/nbench/nbio.c
+++ b/source4/torture/nbench/nbio.c
@@ -181,10 +181,11 @@ static struct smbcli_state *c;
/*
a handler function for oplock break requests
*/
-static BOOL oplock_handler(struct smbcli_transport *transport, uint16_t tid, uint16_t fnum, uint8_t level, void *private)
+static BOOL oplock_handler(struct smbcli_transport *transport, uint16_t tid,
+ uint16_t fnum, BOOL shared, uint8_t level, void *private)
{
struct smbcli_tree *tree = private;
- return smbcli_oplock_ack(tree, fnum, level);
+ return smbcli_oplock_ack(tree, fnum, OPLOCK_BREAK_TO_NONE);
}
void nb_setup(struct smbcli_state *cli, int id)