Fix lame kernel version checking code
authorDenys Vlasenko <vda.linux@googlemail.com>
Thu, 15 Mar 2012 13:36:28 +0000 (14:36 +0100)
committerDenys Vlasenko <vda.linux@googlemail.com>
Thu, 15 Mar 2012 13:36:28 +0000 (14:36 +0100)
commit6e0bfd11ac1aa36713d9a65542ae86dd607ae374
tree08ce0476d17a163b7f5a1391325eab86126bc592
parent61e7aad9fa1a6a5bd5a586e6276767caf12b53f2
Fix lame kernel version checking code

The code "os_release[0] >= '3'" is not good for any
finer-grained checks such as "kernel >= 3.2.1".
Let's proactively fix it.

* strace.c: Change os_release from string to integer.
(get_os_release): Parse uname.release to KERNEL_VERSION
representation.
(init): Convert kernel version check to KERNEL_VERSION.

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
strace.c