From 12ede1732a59f60453815471f7f56870dc2e9046 Mon Sep 17 00:00:00 2001 From: Jeremy Allison Date: Fri, 4 Jun 2021 12:27:38 -0700 Subject: [PATCH] s3: smbd: Cleanup - make SearchDir() static. It's only used in dir.c Signed-off-by: Jeremy Allison Reviewed-by: Ralph Boehme --- source3/smbd/dir.c | 4 +++- source3/smbd/proto.h | 1 - 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/source3/smbd/dir.c b/source3/smbd/dir.c index 946d86de3fd..d20bfa142ab 100644 --- a/source3/smbd/dir.c +++ b/source3/smbd/dir.c @@ -89,6 +89,8 @@ static void DirCacheAdd(struct smb_Dir *dir_hnd, const char *name, long offset); static int smb_Dir_destructor(struct smb_Dir *dir_hnd); +static bool SearchDir(struct smb_Dir *dir_hnd, const char *name, long *poffset); + #define INVALID_DPTR_KEY (-3) /**************************************************************************** @@ -1709,7 +1711,7 @@ static void DirCacheAdd(struct smb_Dir *dir_hnd, const char *name, long offset) Don't check for veto or invisible files. ********************************************************************/ -bool SearchDir(struct smb_Dir *dir_hnd, const char *name, long *poffset) +static bool SearchDir(struct smb_Dir *dir_hnd, const char *name, long *poffset) { int i; const char *entry = NULL; diff --git a/source3/smbd/proto.h b/source3/smbd/proto.h index b9131ba5bd9..45d720c0808 100644 --- a/source3/smbd/proto.h +++ b/source3/smbd/proto.h @@ -243,7 +243,6 @@ const char *ReadDirName(struct smb_Dir *dir_hnd, long *poffset, void RewindDir(struct smb_Dir *dir_hnd, long *poffset); void SeekDir(struct smb_Dir *dirp, long offset); long TellDir(struct smb_Dir *dirp); -bool SearchDir(struct smb_Dir *dirp, const char *name, long *poffset); NTSTATUS can_delete_directory(struct connection_struct *conn, const char *dirname); bool have_file_open_below(connection_struct *conn, -- 2.34.1