From 96beb8d1223d76de97b620973a35e744692e4e7b Mon Sep 17 00:00:00 2001 From: Thierry Vignaud Date: Sun, 20 Jan 2013 21:07:49 +0000 Subject: (update_provides_files) simplify: let callee compute the length --- URPM.xs | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/URPM.xs b/URPM.xs index 4e90a1b..b823ca9 100644 --- a/URPM.xs +++ b/URPM.xs @@ -935,12 +935,8 @@ update_provides_files(const URPM__Package pkg, HV *provides) { struct rpmtd_s td; if (headerGet(pkg->h, RPMTAG_OLDFILENAMES, &td, HEADERGET_DEFAULT)) { - for (i = 0; i < rpmtdCount(&td); i++) { - const char *s = rpmtdNextString(&td); - len = strlen(s); - - update_hash_entry(provides, s, len, 0, 0, pkg); - } + for (i = 0; i < rpmtdCount(&td); i++) + update_hash_entry(provides, rpmtdNextString(&td), 0, 0, 0, pkg); rpmtdFreeData(&td); } -- cgit v1.2.1