This should be where get_share_mode_lock() is located.
BUG: https://bugzilla.samba.org/show_bug.cgi?id=15125
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
(unsigned int)e->name_hash);
}
-/*******************************************************************
- Fetch a share mode where we know one MUST exist. This call reference
- counts it internally to allow for nested lock fetches.
-********************************************************************/
-
-struct share_mode_lock *get_existing_share_mode_lock(TALLOC_CTX *mem_ctx,
- const struct file_id id)
-{
- return get_share_mode_lock(mem_ctx, id, NULL, NULL, NULL);
-}
-
struct rename_share_filename_state {
struct share_mode_lock *lck;
struct messaging_context *msg_ctx;
char *share_mode_str(TALLOC_CTX *ctx, int num,
const struct file_id *id,
const struct share_mode_entry *e);
-struct share_mode_lock *get_existing_share_mode_lock(TALLOC_CTX *mem_ctx,
- struct file_id id);
bool rename_share_filename(struct messaging_context *msg_ctx,
struct share_mode_lock *lck,
return 0;
}
+/*******************************************************************
+ Fetch a share mode where we know one MUST exist. This call reference
+ counts it internally to allow for nested lock fetches.
+********************************************************************/
+
+struct share_mode_lock *get_existing_share_mode_lock(TALLOC_CTX *mem_ctx,
+ const struct file_id id)
+{
+ return get_share_mode_lock(mem_ctx, id, NULL, NULL, NULL);
+}
+
struct share_mode_do_locked_state {
TDB_DATA key;
void (*fn)(const uint8_t *buf,
const char *servicepath,
const struct smb_filename *smb_fname,
const struct timespec *old_write_time);
+struct share_mode_lock *get_existing_share_mode_lock(TALLOC_CTX *mem_ctx,
+ struct file_id id);
bool del_share_mode(struct share_mode_lock *lck,
struct files_struct *fsp);
#include "vfs.h"
#include "smbd/proto.h"
#include "locking/proto.h"
+#include "locking/share_mode_lock.h"
#include "smbd/fd_handle.h"
#if defined(WITH_SMB1SERVER)
#include "smbd/smb1_message.h"