summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/binutils/binutils-2.23.2/backport/binutils-replace-strncat-with-strcat.patch
diff options
context:
space:
mode:
authorAdrian Dudau <adrian.dudau@enea.com>2013-12-12 13:38:32 +0100
committerAdrian Dudau <adrian.dudau@enea.com>2013-12-12 13:50:20 +0100
commite2e6f6fe07049f33cb6348780fa975162752e421 (patch)
treeb1813295411235d1297a0ed642b1346b24fdfb12 /meta/recipes-devtools/binutils/binutils-2.23.2/backport/binutils-replace-strncat-with-strcat.patch
downloadpoky-e2e6f6fe07049f33cb6348780fa975162752e421.tar.gz
initial commit of Enea Linux 3.1
Migrated from the internal git server on the dora-enea branch Signed-off-by: Adrian Dudau <adrian.dudau@enea.com>
Diffstat (limited to 'meta/recipes-devtools/binutils/binutils-2.23.2/backport/binutils-replace-strncat-with-strcat.patch')
-rw-r--r--meta/recipes-devtools/binutils/binutils-2.23.2/backport/binutils-replace-strncat-with-strcat.patch26
1 files changed, 26 insertions, 0 deletions
diff --git a/meta/recipes-devtools/binutils/binutils-2.23.2/backport/binutils-replace-strncat-with-strcat.patch b/meta/recipes-devtools/binutils/binutils-2.23.2/backport/binutils-replace-strncat-with-strcat.patch
new file mode 100644
index 0000000000..bc8f92b8ae
--- /dev/null
+++ b/meta/recipes-devtools/binutils/binutils-2.23.2/backport/binutils-replace-strncat-with-strcat.patch
@@ -0,0 +1,26 @@
1Upstream-Status: Backport
2
3* arc-dis.c (write_comments_): Don't use strncat due to
4 the size of state->commentBuffer pointer isn't predictable.
5
6binutils build will fail on Fedora18+.
7binutils-2.23.1/opcodes/arc-dis.c:430:13: error: argument to 'sizeof' in '__builtin_strncat' call is the same expression as the destination; did you mean to provide an explicit length? [-Werror=sizeof-pointer-memaccess]
8 sizeof (state->commentBuffer));
9 ^
10
11The original commit is http://sourceware.org/cgi-bin/cvsweb.cgi/src/opcodes/arc-dis.c.diff?r1=1.17&r2=1.18&cvsroot=src
12
13Signed-off-by: Zhenhua Luo <zhenhua.luo@freescale.com>
14
15--- binutils-2.23.1/opcodes/arc-dis.c.orig 2013-03-13 00:10:27.978498158 -0500
16+++ binutils-2.23.1/opcodes/arc-dis.c 2013-03-13 00:11:28.297499381 -0500
17@@ -426,8 +426,7 @@
18 strcpy (state->commentBuffer, comment_prefix);
19 else
20 strcat (state->commentBuffer, ", ");
21- strncat (state->commentBuffer, state->comm[i],
22- sizeof (state->commentBuffer));
23+ strcat (state->commentBuffer, state->comm[i]);
24 }
25 }
26 }