mirror of
https://github.com/samba-team/samba.git
synced 2025-01-31 01:48:16 +03:00
r15632: Remove length limitation from the winbind cache cleanup traversal.
Guenther
This commit is contained in:
parent
b591892800
commit
181fa02497
@ -2101,19 +2101,14 @@ static int traverse_fn_cleanup(TDB_CONTEXT *the_tdb, TDB_DATA kbuf,
|
|||||||
TDB_DATA dbuf, void *state)
|
TDB_DATA dbuf, void *state)
|
||||||
{
|
{
|
||||||
struct cache_entry *centry;
|
struct cache_entry *centry;
|
||||||
char buf[1024];
|
|
||||||
|
|
||||||
if (!snprintf(buf, kbuf.dsize + 1, "%s", kbuf.dptr)) {
|
centry = wcache_fetch_raw(kbuf.dptr);
|
||||||
return 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
centry = wcache_fetch_raw(buf);
|
|
||||||
if (!centry) {
|
if (!centry) {
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!NT_STATUS_IS_OK(centry->status)) {
|
if (!NT_STATUS_IS_OK(centry->status)) {
|
||||||
DEBUG(10,("deleting centry %s\n", buf));
|
DEBUG(10,("deleting centry %s\n", kbuf.dptr));
|
||||||
tdb_delete(the_tdb, kbuf);
|
tdb_delete(the_tdb, kbuf);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user