}
// Check changelog_limit
- if ((options->changelog_limit < 0) || (options->changelog_limit > 100)) {
+ if ((options->changelog_limit < -1)) {
g_warning("Wrong changelog limit \"%d\" - Using 10", options->changelog_limit);
options->changelog_limit = DEFAULT_CHANGELOG_LIMIT;
}
while ((rpmtdNext(changelogtimes) != -1) &&
(rpmtdNext(changelognames) != -1) &&
(rpmtdNext(changelogtexts) != -1) &&
- (changelog_limit > 0))
+ (changelog_limit > 0 || changelog_limit == -1))
{
gint64 time = rpmtdGetNumber(changelogtimes);
}
pkg->changelogs = g_slist_prepend(pkg->changelogs, changelog);
- changelog_limit--;
+ if (changelog_limit != -1)
+ changelog_limit--;
// If a previous entry has the same time, increment time of the previous
// entry by one. Ugly but works!