diff --git a/source3/smbd/dir.c b/source3/smbd/dir.c index 541e7cfff62..7483e6f5de4 100644 --- a/source3/smbd/dir.c +++ b/source3/smbd/dir.c @@ -276,7 +276,8 @@ void dptr_closecnum(connection_struct *conn) for(dptr = sconn->searches.dirptrs; dptr; dptr = next) { next = dptr->next; if (dptr->conn == conn) { - dptr_close_internal(dptr); + int key = dptr->dnum; + dptr_close(sconn, &key); } } }