[-]
[+]
|
Deleted |
busybox-1.10.0-dmesg-size.patch
|
@@ -1,26 +0,0 @@
---- util-linux/dmesg.c.orig 2008-06-25 14:51:38.000000000 +0200
-+++ util-linux/dmesg.c 2008-07-06 10:12:12.000000000 +0200
-@@ -12,6 +12,14 @@
- #include <sys/klog.h>
- #include "libbb.h"
-
-+static int kernel_ringbuffer_size(void)
-+{
-+ int len = klogctl(10, NULL, 0);
-+ if (len > 0)
-+ return len;
-+ return 16384;
-+}
-+
- int dmesg_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE;
- int dmesg_main(int argc ATTRIBUTE_UNUSED, char **argv)
- {
-@@ -31,7 +39,7 @@
- return EXIT_SUCCESS;
- }
-
-- len = (flags & OPT_s) ? xatoul_range(size, 2, INT_MAX) : 16384;
-+ len = (flags & OPT_s) ? xatoul_range(size, 2, INT_MAX) : kernel_ringbuffer_size();
- buf = xmalloc(len);
- len = klogctl(3 + (flags & OPT_c), buf, len);
- if (len < 0)
|
[-]
[+]
|
Added |
busybox-1.11.0-dmesg-size.patch
^
|
@@ -0,0 +1,26 @@
+--- util-linux/dmesg.c.orig 2008-06-25 14:51:38.000000000 +0200
++++ util-linux/dmesg.c 2008-07-06 10:12:12.000000000 +0200
+@@ -12,6 +12,14 @@
+ #include <sys/klog.h>
+ #include "libbb.h"
+
++static int kernel_ringbuffer_size(void)
++{
++ int len = klogctl(10, NULL, 0);
++ if (len > 0)
++ return len;
++ return 16384;
++}
++
+ int dmesg_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE;
+ int dmesg_main(int argc ATTRIBUTE_UNUSED, char **argv)
+ {
+@@ -31,7 +39,7 @@
+ return EXIT_SUCCESS;
+ }
+
+- len = (flags & OPT_s) ? xatoul_range(size, 2, INT_MAX) : 16384;
++ len = (flags & OPT_s) ? xatoul_range(size, 2, INT_MAX) : kernel_ringbuffer_size();
+ buf = xmalloc(len);
+ len = klogctl(3 + (flags & OPT_c), buf, len);
+ if (len < 0)
|