From 288d71678b02effdb910e8ebb811d0f502a75166 Mon Sep 17 00:00:00 2001 From: Jeremy Allison Date: Mon, 8 Jul 2019 15:35:20 -0700 Subject: [PATCH] s3: smbd: Remove unused dptr_idleoldest() and dptr_idle() functions. Signed-off-by: Jeremy Allison Reviewed-by: Andreas Schneider --- source3/smbd/dir.c | 46 ---------------------------------------------- 1 file changed, 46 deletions(-) diff --git a/source3/smbd/dir.c b/source3/smbd/dir.c index b53f0dc6c2e..b6b7f40bb81 100644 --- a/source3/smbd/dir.c +++ b/source3/smbd/dir.c @@ -107,52 +107,6 @@ bool init_dptrs(struct smbd_server_connection *sconn) return true; } -#if 0 -/**************************************************************************** - Idle a dptr - the directory is closed but the control info is kept. -****************************************************************************/ - -static void dptr_idle(struct dptr_struct *dptr) -{ - if (dptr->dir_hnd) { - DEBUG(4,("Idling dptr dnum %d\n",dptr->dnum)); - TALLOC_FREE(dptr->dir_hnd); - TALLOC_FREE(dptr->dptr_cache); - dptr->counter = 0; - } -} - -/**************************************************************************** - Idle the oldest dptr. -****************************************************************************/ - -static void dptr_idleoldest(struct smbd_server_connection *sconn) -{ - struct dptr_struct *dptr; - - /* - * Go to the end of the list. - */ - dptr = DLIST_TAIL(sconn->searches.dirptrs); - - if(!dptr) { - DEBUG(0,("No dptrs available to idle ?\n")); - return; - } - - /* - * Idle the oldest pointer. - */ - - for(; dptr; dptr = DLIST_PREV(dptr)) { - if (dptr->dir_hnd) { - dptr_idle(dptr); - return; - } - } -} -#endif - /**************************************************************************** Get the struct dptr_struct for a dir index. ****************************************************************************/ -- 2.47.3