]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
s3: smbd: Remove dptr_close().
authorJeremy Allison <jra@samba.org>
Wed, 17 Jul 2019 21:58:25 +0000 (14:58 -0700)
committerRalph Boehme <slow@samba.org>
Tue, 6 Aug 2019 14:23:35 +0000 (14:23 +0000)
No longer used.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
source3/smbd/dir.c
source3/smbd/proto.h

index 1ca167bb1ecd678e9389fc95941af6bc625acd87..bc80b4d8f1cc8f871c4a66fc28420198c93859f3 100644 (file)
@@ -207,44 +207,6 @@ done:
        TALLOC_FREE(dptr);
 }
 
-/****************************************************************************
- Close a dptr given a key. SMB1 *only*.
-****************************************************************************/
-
-void dptr_close(struct smbd_server_connection *sconn, int *key)
-{
-       struct dptr_struct *dptr;
-       files_struct *fsp = NULL;
-       struct smb_Dir *dir_hnd = NULL;
-
-       SMB_ASSERT(!sconn->using_smb2);
-
-       if(*key == INVALID_DPTR_KEY)
-               return;
-
-       dptr = dptr_get(sconn, *key);
-
-       if (!dptr) {
-               DEBUG(0,("Invalid key %d given to dptr_close\n", *key));
-               return;
-       }
-
-       dir_hnd = dptr->dir_hnd;
-
-       if (dir_hnd != NULL && dir_hnd->fsp != NULL) {
-               SMB_ASSERT(dir_hnd->fsp->dptr->dir_hnd == dir_hnd);
-               fsp = dir_hnd->fsp;
-       }
-
-       dptr_close_internal(dptr);
-
-       if (fsp != NULL) {
-               fsp->dptr = NULL;
-       }
-
-       *key = INVALID_DPTR_KEY;
-}
-
 /****************************************************************************
  Close all dptrs for a cnum.
 ****************************************************************************/
index a07614f996989b75c077e2b4242fc7b9ba7a4313..b8e1468680cc80949c23b78bdf429b6bfab8c093 100644 (file)
@@ -183,7 +183,6 @@ bool init_dptrs(struct smbd_server_connection *sconn);
 const char *dptr_path(struct smbd_server_connection *sconn, int key);
 const char *dptr_wcard(struct smbd_server_connection *sconn, int key);
 uint16_t dptr_attr(struct smbd_server_connection *sconn, int key);
-void dptr_close(struct smbd_server_connection *sconn, int *key);
 void dptr_closecnum(connection_struct *conn);
 NTSTATUS dptr_create(connection_struct *conn,
                struct smb_request *req,