Thread (4 messages) flat view 4 messages, 2 authors, 14d ago

Re: [PATCH] fbdev: platinumfb: replace strcpy with strscpy

From: yuebingkun <hidden>
Date: 2026-08-18 00:48:25
Also in: dri-devel, lkml

On Mon, 17 Aug 2026, David Laight wrote:
There is no point using strscpy() to copy quoted strings into arrays.
Indeed, if the string is too long the kernel build will fail if strcpy()
is used but strscpy() will silently truncate the strings.
So strscpy() is actually worse here.
Thank you for the explanation. You are right, for copying a known
string literal into a fixed-size array, strcpy() is actually safer
because the compiler can catch overflow at build time. I will drop
this patch.

---
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help