tech-kern archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: Usage of strncpy in the kernel
On Sun, Jan 05, 2025 at 01:06:41PM -0800, Greg A. Woods wrote:
> > I used the "l" because like strlcpy they (should) check all the
> > lengths and won't overrun.
>
> I think you may be confusing strlcpy() and strlcat().
Huh? The difference between strcpy and strlcpy is the "l" and the
length checking.
> There's no "checking of the length" in strlcpy(). There's
> nothing to check [*].
Right, the length argument does nothing and serves no purpose. Uh huh.
I don't really follow where you're coming from.
--
David A. Holland
dholland%netbsd.org@localhost
Home |
Main Index |
Thread Index |
Old Index