diff options
author | Jindrich Novy <jnovy@redhat.com> | 2009-04-16 14:13:34 +0200 |
---|---|---|
committer | Jindrich Novy <jnovy@redhat.com> | 2009-04-16 14:13:34 +0200 |
commit | e7ce53c3aea8d11d083e220bfb2e4c6b4ced9a5a (patch) | |
tree | 945c60171653f1fb6496444f4af6813cb0cce877 /build | |
parent | 3b9f0b817e635b4cf03e500d83bc3e9ba60ff9f9 (diff) | |
download | rpm-e7ce53c3aea8d11d083e220bfb2e4c6b4ced9a5a.tar.gz rpm-e7ce53c3aea8d11d083e220bfb2e4c6b4ced9a5a.tar.bz2 rpm-e7ce53c3aea8d11d083e220bfb2e4c6b4ced9a5a.zip |
Introduce changelog trimming in binary packages feature (ticket #47)
Diffstat (limited to 'build')
-rw-r--r-- | build/parseChangelog.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/build/parseChangelog.c b/build/parseChangelog.c index 96e591c3a..6c6e6a991 100644 --- a/build/parseChangelog.c +++ b/build/parseChangelog.c @@ -117,6 +117,7 @@ static rpmRC addChangelog(Header h, StringBuf sb) int i; time_t time; time_t lastTime = 0; + time_t trimtime = rpmExpandNumeric("%{?_changelog_trimtime}"); char *date, *name, *text, *next; s = getStringBuf(sb); @@ -198,7 +199,10 @@ static rpmRC addChangelog(Header h, StringBuf sb) *s-- = '\0'; } - addChangelogEntry(h, time, name, text); + if ( !trimtime || time >= trimtime ) { + addChangelogEntry(h, time, name, text); + } else break; + s = next; } |