summaryrefslogtreecommitdiffstats
path: root/arch/sparc/kernel/ds.c
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2017-06-01 18:42:46 +0200
committerDavid S. Miller <davem@davemloft.net>2017-06-01 18:42:46 +0200
commit0fde7ad71ee371ede73b3f326e58f9e8d102feb6 (patch)
treeaa2ba307fb12f24faf327717a3475de36df033f3 /arch/sparc/kernel/ds.c
parentarch/sparc: increase CONFIG_NODES_SHIFT on SPARC64 to 5 (diff)
downloadlinux-0fde7ad71ee371ede73b3f326e58f9e8d102feb6.tar.xz
linux-0fde7ad71ee371ede73b3f326e58f9e8d102feb6.zip
sparc64: Fix build warnings with gcc 7.
arch/sparc/kernel/ds.c: In function ‘register_services’: arch/sparc/kernel/ds.c:912:3: error: ‘strcpy’: writing at least 1 byte into a region of size 0 overflows the destination Reported-by: Anatoly Pugachev <matorola@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'arch/sparc/kernel/ds.c')
-rw-r--r--arch/sparc/kernel/ds.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/sparc/kernel/ds.c b/arch/sparc/kernel/ds.c
index b542cc7c8d94..f87265afb175 100644
--- a/arch/sparc/kernel/ds.c
+++ b/arch/sparc/kernel/ds.c
@@ -909,7 +909,7 @@ static int register_services(struct ds_info *dp)
pbuf.req.handle = cp->handle;
pbuf.req.major = 1;
pbuf.req.minor = 0;
- strcpy(pbuf.req.svc_id, cp->service_id);
+ strcpy(pbuf.id_buf, cp->service_id);
err = __ds_send(lp, &pbuf, msg_len);
if (err > 0)