From: Rickard Strandqvist Date: Sat, 26 Jul 2014 13:58:22 +0000 (+0200) Subject: arch: blackfin: kernel: setup.c: Cleaning up missing null-terminate in conjunction... X-Git-Tag: submit/tizen/20160607.132125~2557^2~14 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=4eb147c83f34e00184557923d2bf93f593deb41c;p=sdk%2Femulator%2Femulator-kernel.git arch: blackfin: kernel: setup.c: Cleaning up missing null-terminate in conjunction with strncpy Replacing strncpy with strlcpy to avoid strings that lacks null terminate. Signed-off-by: Rickard Strandqvist Signed-off-by: Steven Miao --- diff --git a/arch/blackfin/kernel/setup.c b/arch/blackfin/kernel/setup.c index 4f424ae3..ad82468 100644 --- a/arch/blackfin/kernel/setup.c +++ b/arch/blackfin/kernel/setup.c @@ -1464,5 +1464,5 @@ void __init cmdline_init(const char *r0) { early_shadow_stamp(); if (r0) - strncpy(command_line, r0, COMMAND_LINE_SIZE); + strlcpy(command_line, r0, COMMAND_LINE_SIZE); }