Messages in this thread | | | Date | Mon, 18 Mar 2024 16:49:52 -0700 | From | Kees Cook <> | Subject | Re: [PATCH] soc: qcom: cmd-db: replace deprecated strncpy with memcpy |
| |
On Mon, Mar 18, 2024 at 03:47:38PM -0700, Justin Stitt wrote: > Gotcha, I was operating under the assumption that we needed to know > the size of id at compile time. Apparently __builtin_object_size(_, 1) > will return SIZE_T_MAX if we don't know the size of something. Sending > a v2.
Yeah, it only requires to know the compile-time size of the destination buffer.
-- Kees Cook
| |