From: Volker Lendecke Date: Mon, 29 May 2023 10:47:34 +0000 (+0200) Subject: smbd: Make SeekDir()/TellDir() static to dir.c X-Git-Tag: talloc-2.4.1~477 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=288e591bfd4efd6a1b1c2239e5cf43c79ea3446b;p=thirdparty%2Fsamba.git smbd: Make SeekDir()/TellDir() static to dir.c Signed-off-by: Volker Lendecke Reviewed-by: Jeremy Allison --- diff --git a/source3/smbd/dir.c b/source3/smbd/dir.c index 09029ee0c23..9ebd1576be0 100644 --- a/source3/smbd/dir.c +++ b/source3/smbd/dir.c @@ -91,6 +91,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); +static void SeekDir(struct smb_Dir *dirp, long offset); +static long TellDir(struct smb_Dir *dirp); #define INVALID_DPTR_KEY (-3) @@ -1685,7 +1687,7 @@ void RewindDir(struct smb_Dir *dir_hnd, long *poffset) Seek a dir. ********************************************************************/ -void SeekDir(struct smb_Dir *dirp, long offset) +static void SeekDir(struct smb_Dir *dirp, long offset) { if (offset == dirp->offset) { /* @@ -1723,7 +1725,7 @@ void SeekDir(struct smb_Dir *dirp, long offset) Tell a dir position. ********************************************************************/ -long TellDir(struct smb_Dir *dir_hnd) +static long TellDir(struct smb_Dir *dir_hnd) { return(dir_hnd->offset); } diff --git a/source3/smbd/proto.h b/source3/smbd/proto.h index 5361678a922..b7136f2c9b8 100644 --- a/source3/smbd/proto.h +++ b/source3/smbd/proto.h @@ -233,8 +233,6 @@ NTSTATUS OpenDir_from_pathref(TALLOC_CTX *mem_ctx, const char *ReadDirName(struct smb_Dir *dir_hnd, long *poffset, SMB_STRUCT_STAT *sbuf, char **talloced); void RewindDir(struct smb_Dir *dir_hnd, long *poffset); -void SeekDir(struct smb_Dir *dirp, long offset); -long TellDir(struct smb_Dir *dirp); NTSTATUS can_delete_directory(struct connection_struct *conn, const char *dirname); bool have_file_open_below(connection_struct *conn,