[Centos] httpd trademark issue -- here it is!

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



On Saturday, 18 December 2004, at 06:26:26 (-0800),
Rick Graves wrote:

> Compare:
> 
> httpd-2.0.46-44.ent.centos.1.i386.rpm
> httpd-2.0.46-44.ent.centos.2.i386.rpm 
> 
> By "non-contiguous", I meant that the "1" and "2" digits are
> separated from the main version number, 2.0.46-44.

The version number is actually "2.0.46," and the release is
"44.ent.centos.1".  If your code isn't catching that, it's not doing
the comparison right.

I have some perl code and some C code that does pretty reliable
version comparisons, in some cases better than rpm does.  Let me know
if you're interested.  But the basic idea is to split the version and
release into numeric and non-numeric portions and compare each one in
turn.  It's not a straight string compare; if it were, 2.0.46 would
seem to be a higher version than 2.0.127.  Numbers are compared
numerically for that reason.  So the comparison becomes this:

2 . 0 . 46   44 .ent.centos. 1
2 . 0 . 46   44 .ent.centos. 2

Clearly, 1 < 2, so the latter is the newer package.

HTH,
Michael

-- 
Michael Jennings (a.k.a. KainX)  http://www.kainx.org/  <mej@xxxxxxxxx>
n + 1, Inc., http://www.nplus1.net/       Author, Eterm (www.eterm.org)
-----------------------------------------------------------------------
 "She'd still say, 'I love you' if I asked, but she never volunteers.
  Somehow what she never says means more than all the other words I
  hear."                     -- BlackHawk, "I Sure Can Smell the Rain"


[Index of Archives]     [CentOS]     [CentOS Announce]     [CentOS Development]     [CentOS ARM Devel]     [CentOS Docs]     [CentOS Virtualization]     [Carrier Grade Linux]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Linux USB]
  Powered by Linux