Am Freitag, 3. April 2015, 01:54:24 schrieb Thomas Liske: […] > Re, Re Thomas,
> On 04/01/2015 02:14 PM, Thomas Liske wrote: > > The expected kernel version reported by needrestart is the first > > one... > > I need to review why i.e. 4.9 looses against 3.10. > > the kernel version sorting was based on Sort::Naturally which does not > work since the rightmost integer found in the version string is used as > the primary sorting index. Therefore 4.0 will loose against any 3.x > (x>0) kernels :-/ > > Upstream has been fixed by porting the version comparing stuff from > Dpkg::Version into a simplified implementation in needrestart. This > results in the expected kernel version sorting order: > > $VAR1 = [ > '4.20.0-rc6-tp520-btrfs-trim+', > '4.20.0', > '4.19.0-rc6-tp520-btrfs-trim+', > '4.19.0', > '4.10', > '4.9', > '4.4.0-foo', > '4.4.0', > '4.0.0-rc6-tp520-btrfs-trim+', > '4.0.0', > '4.0', > '3.19.3-rc6-tp521-btrfs-trim+', > '3.19.3-rc6-tp520-btrfs-trim+', > '3.19.3-a7-tp521-btrfs-trim+', > '3.19.3', > '3.19.0-rc7-tp520+', > '3.10', > '3.9', > '3.3', > '2.6', > '' > ]; > > (4.20.0-rc6 wins against 4.20.0 which is expected since -rc6 could also > be a usual CONFIG_LOCALVERSION string) Hmmm, but when I have a 4.20.0 final release compiled needrestart would treat it as older? That doesn´t make much sense for me. I think ideally it would use the same ordering as the boot manager. And grub2 definately puts 4.20.0 about 4.20.0-rc6. Thank you, -- Martin 'Helios' Steigerwald - http://www.Lichtvoll.de GPG: 03B0 0D6C 0040 0710 4AFA B82F 991B EAAC A599 84C7 -- To UNSUBSCRIBE, email to [email protected] with a subject of "unsubscribe". Trouble? Contact [email protected]

