2 ms·
strlcpy(3) is actually used quite heavily throughout the Linux kernel: http://lxr.free-electrons.com/ident?i=strlcpy http://lxr.free-electrons.com/ident?i=strlc
by vezzy-fnord 11y ago
strlcpy(3) is actually used quite heavily throughout the Linux kernel: http://lxr.free-electrons.com/ident?i=strlcpy http://lxr.free-electrons.com/ident?i=strlcpy
I'm not sure what Linus intended.
- shmerl 11y agoThough for some reason it still didn't make it into glibc.
- heinrich5991 11y agoThat's because C never has problems with buffer overflows. What's far worse: strlcpy truncates the string in case it wouldn't fit the buffer!
- mzs 11y agoUlrich Drepper was the maintainer of glibc at the time: https://www.sourceware.org/ml/libc-alpha/2000-08/msg00061.html https://www.sourceware.org/ml/libc-alpha/2000-08/msg00061.ht...
- ori_b 11y agoThe kernel developers aren't the glibc developers.