Separate match iterator allocation vs initialization
authorPanu Matilainen <pmatilai@redhat.com>
Tue, 26 Oct 2010 06:54:55 +0000 (09:54 +0300)
committerPanu Matilainen <pmatilai@redhat.com>
Tue, 26 Oct 2010 06:54:55 +0000 (09:54 +0300)
commita40598b228e3e67f4e7b4ec9ce9de6dddce33735
tree9a4776de83820d46910d2b2c00f99a116d4b9596
parent0d4b7b8f3a0a2f0de7a30fd51c86be6849e54329
Separate match iterator allocation vs initialization
- There's exactly one spot within rpm which needs the former behavior
  of rpmdbInitIterator() on a secondary index with keyp of NULL:
  rpmFindBaseNamesInDB(): it wants an empty iterator on RPMDBI_BASENAMES,
  which is then extended as it progresses. Starting with commit
  c70e076e088589f65160c05ee7cc8db0b3db6d7e, rpmdbInitIterator()
  however returns the actual index in that case, which is not
  optimal for rpmFindBaseNamesInDB(). Handle the basenames in db
  as the special case it is, and have it explicitly create an
  empty iterator with the new call.
lib/rpmdb.c
lib/rpmdb_internal.h
lib/transaction.c