mirror of
https://github.com/samba-team/samba.git
synced 2024-12-25 23:21:54 +03:00
removed some debug code
This commit is contained in:
parent
657836599a
commit
1f6240daae
@ -188,39 +188,34 @@ static int traverse_fn(TDB_CONTEXT *db, TDB_DATA key, TDB_DATA dbuf, void *state
|
||||
|
||||
static void merge_test()
|
||||
{
|
||||
int klen, dlen;
|
||||
int i;
|
||||
int klen, dlen;
|
||||
int i;
|
||||
char keys[5][2];
|
||||
TDB_DATA key, data;
|
||||
|
||||
TDB_DATA key, data;
|
||||
|
||||
for (i = 0; i < 5; i++) {
|
||||
sprintf(keys[i], "%d", i);
|
||||
key.dptr = keys[i];
|
||||
key.dsize = 2;
|
||||
|
||||
data.dptr = "test";
|
||||
data.dsize = 4;
|
||||
|
||||
if (tdb_store(db, key, data, TDB_REPLACE) != 0) {
|
||||
fatal("tdb_store failed");
|
||||
}
|
||||
key.dptr = keys[i];
|
||||
key.dsize = 2;
|
||||
|
||||
data.dptr = "test";
|
||||
data.dsize = 4;
|
||||
|
||||
if (tdb_store(db, key, data, TDB_REPLACE) != 0) {
|
||||
fatal("tdb_store failed");
|
||||
}
|
||||
}
|
||||
|
||||
key.dptr = keys[0];
|
||||
tdb_delete(db, key);
|
||||
tdb_printfreelist(db);
|
||||
key.dptr = keys[4];
|
||||
tdb_delete(db, key);
|
||||
tdb_printfreelist(db);
|
||||
key.dptr = keys[2];
|
||||
tdb_delete(db, key);
|
||||
tdb_printfreelist(db);
|
||||
key.dptr = keys[1];
|
||||
tdb_delete(db, key);
|
||||
tdb_printfreelist(db);
|
||||
key.dptr = keys[3];
|
||||
tdb_delete(db, key);
|
||||
tdb_printfreelist(db);
|
||||
}
|
||||
|
||||
int main(int argc, char *argv[])
|
||||
|
Loading…
Reference in New Issue
Block a user