summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/e2fsprogs
diff options
context:
space:
mode:
authorRobert Yang <liezhi.yang@windriver.com>2013-07-18 17:50:50 +0800
committerRichard Purdie <richard.purdie@linuxfoundation.org>2013-08-26 11:47:18 +0100
commitf1e6091a1b20f66ede7098e54a2974232943c1c7 (patch)
tree3cf4c6b9e3d9c1e4d8952550c05bb63676045806 /meta/recipes-devtools/e2fsprogs
parent66eac2df0ccd0c7e17bf7f1117a7612d6151629c (diff)
downloadpoky-f1e6091a1b20f66ede7098e54a2974232943c1c7.tar.gz
e2fsprogs: the max length of debugfs argument is too short
The max length of debugfs argument is 256 which is too short, the arguments are two paths, the PATH_MAX is 4096 according to /usr/include/linux/limits.h, so use BUFSIZ (which is 8192 on Linux systems), that's also what the ss library uses. This patch has been reviewed by the linux-ext4 mailing list, but isn't merged atm. [YOCTO #3848] (From OE-Core rev: a916a127768291ca7c614976e05c90153fec2956) Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-devtools/e2fsprogs')
-rw-r--r--meta/recipes-devtools/e2fsprogs/e2fsprogs-1.42.8/debugfs-too-short.patch41
-rw-r--r--meta/recipes-devtools/e2fsprogs/e2fsprogs_1.42.8.bb1
2 files changed, 42 insertions, 0 deletions
diff --git a/meta/recipes-devtools/e2fsprogs/e2fsprogs-1.42.8/debugfs-too-short.patch b/meta/recipes-devtools/e2fsprogs/e2fsprogs-1.42.8/debugfs-too-short.patch
new file mode 100644
index 0000000000..607305be54
--- /dev/null
+++ b/meta/recipes-devtools/e2fsprogs/e2fsprogs-1.42.8/debugfs-too-short.patch
@@ -0,0 +1,41 @@
1debugfs.c: the max length of debugfs argument is too short
2
3The max length of debugfs argument is 256 which is too short, the
4arguments are two paths, the PATH_MAX is 4096 according to
5/usr/include/linux/limits.h, so use BUFSIZ (which is 8192 on Linux
6systems), that's also what the ss library uses.
7
8Upstream-Status: Submitted
9
10Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
11Acked-by: Darren Hart <dvhart@linux.intel.com>
12---
13 debugfs/debugfs.c | 6 +++++-
14 1 file changed, 5 insertions(+), 1 deletion(-)
15
16diff --git a/debugfs/debugfs.c b/debugfs/debugfs.c
17--- a/debugfs/debugfs.c
18+++ b/debugfs/debugfs.c
19@@ -37,6 +37,10 @@ extern char *optarg;
20 #include "../version.h"
21 #include "jfs_user.h"
22
23+#ifndef BUFSIZ
24+#define BUFSIZ 8192
25+#endif
26+
27 ss_request_table *extra_cmds;
28 const char *debug_prog_name;
29 int sci_idx;
30@@ -2311,7 +2315,7 @@ void do_dump_mmp(int argc EXT2FS_ATTR((unused)), char *argv[])
31 static int source_file(const char *cmd_file, int ss_idx)
32 {
33 FILE *f;
34- char buf[256];
35+ char buf[BUFSIZ];
36 char *cp;
37 int exit_status = 0;
38 int retval;
39--
401.8.1.2
41
diff --git a/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.42.8.bb b/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.42.8.bb
index 928a0cd688..319728ee57 100644
--- a/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.42.8.bb
+++ b/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.42.8.bb
@@ -3,6 +3,7 @@ require e2fsprogs.inc
3 3
4SRC_URI += "file://acinclude.m4 \ 4SRC_URI += "file://acinclude.m4 \
5 file://remove.ldconfig.call.patch \ 5 file://remove.ldconfig.call.patch \
6 file://debugfs-too-short.patch \
6" 7"
7 8
8SRC_URI[md5sum] = "8ef664b6eb698aa6b733df59b17b9ed4" 9SRC_URI[md5sum] = "8ef664b6eb698aa6b733df59b17b9ed4"