}
#endif
-bool is_stat_open(uint32_t access_mask)
+/**
+ * Allowed access mask for stat opens relevant to oplocks
+ **/
+bool is_oplock_stat_open(uint32_t access_mask)
{
const uint32_t stat_open_bits =
(SYNCHRONIZE_ACCESS|
uint16_t new_flags;
bool ok, conflict, have_share_entries;
- if (is_stat_open(access_mask)) {
+ if (is_oplock_stat_open(access_mask)) {
/* Stat open that doesn't trigger oplock breaks or share mode
* checks... ! JRA. */
return NT_STATUS_OK;
return false;
}
- if (e->op_type == NO_OPLOCK && is_stat_open(e->access_mask)) {
+ if (e->op_type == NO_OPLOCK && is_oplock_stat_open(e->access_mask)) {
/*
* We ignore stat opens in the table - they always
* have NO_OPLOCK and never get or cause breaks. JRA.
NTSTATUS status;
bool ok;
- if (is_stat_open(fsp->access_mask)) {
+ if (is_oplock_stat_open(fsp->access_mask)) {
goto grant;
}
* FILE_OVERWRITE and FILE_OVERWRITE_IF add in O_TRUNC,
* which adds FILE_WRITE_DATA to open_access_mask.
*/
- if (is_stat_open(open_access_mask) && lease == NULL) {
+ if (is_oplock_stat_open(open_access_mask) && lease == NULL) {
oplock_request = NO_OPLOCK;
}
}
void change_file_owner_to_parent(connection_struct *conn,
struct smb_filename *inherit_from_dir,
files_struct *fsp);
-bool is_stat_open(uint32_t access_mask);
+bool is_oplock_stat_open(uint32_t access_mask);
NTSTATUS send_break_message(struct messaging_context *msg_ctx,
const struct file_id *id,
const struct share_mode_entry *exclusive,