diff options
Diffstat (limited to 'meta/recipes-core/busybox/busybox-1.20.2/busybox-1.20.2-kernel_ver.patch')
-rw-r--r-- | meta/recipes-core/busybox/busybox-1.20.2/busybox-1.20.2-kernel_ver.patch | 28 |
1 files changed, 0 insertions, 28 deletions
diff --git a/meta/recipes-core/busybox/busybox-1.20.2/busybox-1.20.2-kernel_ver.patch b/meta/recipes-core/busybox/busybox-1.20.2/busybox-1.20.2-kernel_ver.patch deleted file mode 100644 index 69bbe73c64..0000000000 --- a/meta/recipes-core/busybox/busybox-1.20.2/busybox-1.20.2-kernel_ver.patch +++ /dev/null | |||
@@ -1,28 +0,0 @@ | |||
1 | Signed-off-by: Radu Moisan <radu.moisan@intel.com> | ||
2 | Upstream-Status: Pending | ||
3 | |||
4 | --- busybox-1.20.2/libbb/kernel_version.c | ||
5 | +++ busybox-1.20.2-kernel_ver/libbb/kernel_version.c | ||
6 | @@ -20,18 +20,15 @@ | ||
7 | int FAST_FUNC get_linux_version_code(void) | ||
8 | { | ||
9 | struct utsname name; | ||
10 | - char *s; | ||
11 | + char *s, *t; | ||
12 | int i, r; | ||
13 | |||
14 | - if (uname(&name) == -1) { | ||
15 | - bb_perror_msg("can't get system information"); | ||
16 | - return 0; | ||
17 | - } | ||
18 | - | ||
19 | + uname(&name); /* never fails */ | ||
20 | s = name.release; | ||
21 | r = 0; | ||
22 | for (i = 0; i < 3; i++) { | ||
23 | - r = r * 256 + atoi(strtok(s, ".")); | ||
24 | + t = strtok(s, "."); | ||
25 | + r = r * 256 + (t ? atoi(t) : 0); | ||
26 | s = NULL; | ||
27 | } | ||
28 | return r; | ||