Re: [Rpm-maint] recognizing epoch, take two

2011-11-16 Thread Ales Kozumplik
On 11/16/2011 11:20 AM, Michael Schroeder wrote: On Wed, Nov 16, 2011 at 11:17:23AM +0100, Ales Kozumplik wrote: I use long int type to pass the epoch around. This type can both cover the entire range of RPM_INT32_TYPE (the type of epoch value) and -1 for the 'any epoch' semantics. Compared to t

Re: [Rpm-maint] recognizing epoch, take two

2011-11-16 Thread Michael Schroeder
On Wed, Nov 16, 2011 at 11:17:23AM +0100, Ales Kozumplik wrote: > I use long int type to pass the epoch around. This type can both cover the > entire range of RPM_INT32_TYPE (the type of epoch value) and -1 for the > 'any epoch' semantics. Compared to the previous version, it saves us one > malloc

[Rpm-maint] [PATCH] Recognize ":" as a part of a label (ticket #117)

2011-11-16 Thread Ales Kozumplik
- for instance this works now: $ rpm -q perl-4:5.14.1-188.fc16.x86_64 perl-5.14.1-188.fc16.x86_64 --- lib/rpmdb.c | 58 +- 1 files changed, 49 insertions(+), 9 deletions(-) diff --git a/lib/rpmdb.c b/lib/rpmdb.c index e249998..7d4b31e

[Rpm-maint] recognizing epoch, take two

2011-11-16 Thread Ales Kozumplik
I use long int type to pass the epoch around. This type can both cover the entire range of RPM_INT32_TYPE (the type of epoch value) and -1 for the 'any epoch' semantics. Compared to the previous version, it saves us one malloc and is not longer. ___ Rpm-

Re: [Rpm-maint] [PATCH 2/2] Recognize ":" as a part of a label (ticket #117)

2011-11-16 Thread Ales Kozumplik
On 11/15/2011 10:37 AM, Panu Matilainen wrote: /** \ingroup dbi + * Return (newly allocated) integer of the epoch. + * @param s version string optionally containing epoch number + * @retval version only the version part of s + * @return newly allocated epoch integer + */ +static int * splitEpoch(