Enhanced string hash to permit calculating string length on the same call
authorPanu Matilainen <pmatilai@redhat.com>
Tue, 18 Sep 2012 01:34:38 +0000 (04:34 +0300)
committerPanu Matilainen <pmatilai@redhat.com>
Tue, 18 Sep 2012 01:40:20 +0000 (04:40 +0300)
commit76a699701cda144af96f77061b036c7afc10fce4
tree661eb71c16f5d13e34b025d280ab95a3d9ae7b3c
parentbef4be688de3b29fe62d10bf723ad888111853aa
Enhanced string hash to permit calculating string length on the same call

- String hashing needs to walk the entire string anyhow, might as well
  take advantage of this and have it return the string length to avoid
  having to separately call strlen() in the cases where this matters.
- Move the implementation into rpmstrpool.c for inlining possibilities,
  rstrhash() is now just a wrapper to rstrlenhash(). The generic
  hash implementation could not take advantage of this anyway really.
rpmio/rpmstring.c
rpmio/rpmstrpool.c