From: Klaus Kaempf Date: Thu, 14 Feb 2008 14:14:39 +0000 (+0000) Subject: comments X-Git-Tag: BASE-SuSE-Code-12_1-Branch~927 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=a15481d76b0156189cf0648c8d888f4cbc2ab66a;p=platform%2Fupstream%2Flibsolv.git comments --- diff --git a/tools/dumpsolv.c b/tools/dumpsolv.c index 72bafac..3f682d0 100644 --- a/tools/dumpsolv.c +++ b/tools/dumpsolv.c @@ -176,16 +176,23 @@ dump_repoattrs_cb(void *vcbdata, Solvable *s, Repodata *data, Repokey *key, KeyV return 0; } +/* + * dump all attributes for Id

+ */ + void dump_repoattrs(Repo *repo, Id p) { int i; Repodata *data; + /* + * look through all repodata(s) to find the one covering the right range of Ids + */ for (i = 0, data = repo->repodata; i < repo->nrepodata; i++, data++) { - if (data->state == REPODATA_STUB || data->state == REPODATA_ERROR) + if (data->state == REPODATA_STUB || data->state == REPODATA_ERROR) /* skip repodata of wrong state */ continue; - if (p < data->start || p >= data->end) + if (p < data->start || p >= data->end) /* skip repodata of wrong range */ continue; repodata_search(data, p - data->start, 0, dump_repoattrs_cb, 0); }