From bf35116f9d203dcafce808a6c7b3dd5a0db8afbc Mon Sep 17 00:00:00 2001 From: root Date: Tue, 2 Aug 2011 04:35:55 +0000 Subject: Tue Aug 2 04:35:55 UTC 2011 --- extra/parted/linux.c.patch | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 extra/parted/linux.c.patch (limited to 'extra/parted/linux.c.patch') diff --git a/extra/parted/linux.c.patch b/extra/parted/linux.c.patch new file mode 100644 index 000000000..c9feea142 --- /dev/null +++ b/extra/parted/linux.c.patch @@ -0,0 +1,25 @@ +--- a/libparted/arch/linux.c 2011-05-27 14:52:37.000000000 +0200 ++++ b/libparted/arch/linux.c 2011-07-29 20:25:38.000000000 +0200 +@@ -601,17 +601,17 @@ + static int kver = -1; + + struct utsname uts; +- int major; +- int minor; +- int teeny; ++ int major = 0; ++ int minor = 0; ++ int teeny = 0; + + if (kver != -1) + return kver; + + if (uname (&uts)) + return kver = 0; +- if (sscanf (uts.release, "%u.%u.%u", &major, &minor, &teeny) != 3) +- return kver = 0; ++ int n = sscanf (uts.release, "%u.%u.%u", &major, &minor, &teeny); ++ assert (n == 2 || n == 3); + + return kver = KERNEL_VERSION (major, minor, teeny); + } -- cgit v1.2.3-54-g00ecf