ldb_tdb: Add ltdb_idx_to_key() and use it in ltdb_index_filter()