1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-14 19:24:43 +03:00

s3: smbd: Remove the 'close oldest' logic in SMB1search processing.

Expect the client to manage their handles properly.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
This commit is contained in:
Jeremy Allison 2019-07-08 15:23:57 -07:00
parent ff8c8b34b9
commit 1376dc3b84

View File

@ -527,23 +527,12 @@ NTSTATUS dptr_create(connection_struct *conn,
dptr->dnum = bitmap_find(sconn->searches.dptr_bmap, 0); dptr->dnum = bitmap_find(sconn->searches.dptr_bmap, 0);
if(dptr->dnum == -1 || dptr->dnum > 254) { if(dptr->dnum == -1 || dptr->dnum > 254) {
DBG_ERR("returned %d: Error - all old "
/* "dirptrs in use ?\n",
* Try and close the oldest handle not marked for dptr->dnum);
* expect close in the hope that the client has TALLOC_FREE(dptr);
* finished with that one. TALLOC_FREE(dir_hnd);
*/ return NT_STATUS_TOO_MANY_OPENED_FILES;
dptr_close_oldest(sconn, true);
/* Now try again... */
dptr->dnum = bitmap_find(sconn->searches.dptr_bmap, 0);
if(dptr->dnum == -1 || dptr->dnum > 254) {
DEBUG(0,("dptr_create: returned %d: Error - all old dirptrs in use ?\n", dptr->dnum));
TALLOC_FREE(dptr);
TALLOC_FREE(dir_hnd);
return NT_STATUS_TOO_MANY_OPENED_FILES;
}
} }
} else { } else {