From 78bb1258f9e67f3052488c6168c40f94a3258cca Mon Sep 17 00:00:00 2001 From: Rusty Russell Date: Tue, 1 Mar 2011 23:19:18 +1030 Subject: [PATCH] tdb2: remove zero-length write optimization. If benchmarking indicates a problem later, we can restore it. --- ccan/tdb2/io.c | 5 ----- 1 file changed, 5 deletions(-) diff --git a/ccan/tdb2/io.c b/ccan/tdb2/io.c index a9016c4f..866ff085 100644 --- a/ccan/tdb2/io.c +++ b/ccan/tdb2/io.c @@ -236,11 +236,6 @@ static enum TDB_ERROR tdb_write(struct tdb_context *tdb, tdb_off_t off, "Write to read-only database"); } - /* FIXME: Bogus optimization? */ - if (len == 0) { - return TDB_SUCCESS; - } - ecode = tdb->methods->oob(tdb, off + len, 0); if (ecode != TDB_SUCCESS) { return ecode; -- 2.39.2