svn commit: r364071 - head/sys/kern

Steffen Nurpmeso steffen at sdaoden.eu
Mon Aug 10 23:10:16 UTC 2020


Ravi Pokala wrote in
 <B1DCE6F5-7B6E-45A1-8A43-11E04A37145A at panasas.com>:
 |-----Original Message-----
 |From: <owner-src-committers at freebsd.org> on behalf of Mateusz Guzik \
 |<mjg at FreeBSD.org>
 |Date: 2020-08-10, Monday at 03:40
 |To: <src-committers at freebsd.org>, <svn-src-all at freebsd.org>, <svn-src-he\
 |ad at freebsd.org>
 |Subject: svn commit: r364071 - head/sys/kern
 |
 |    Author: mjg
 |    Date: Mon Aug 10 10:40:14 2020
 |    New Revision: 364071
 |    URL: https://svnweb.freebsd.org/changeset/base/364071
 |
 |    Log:
 |      cache: strlcpy -> memcpy
 |
 |But why?

Ach, i like it!  I, coming from (basic ->) perl -> java -> C++ ->
C always hated that C string functions which iterate stuff over
and over again, but especially so if working on buffers of which
the length is known.  I mean, you know, if i know i have a NUL
terminated buffer and its length, why in the world should i use
one of those mysterious C string functions?  I know there is one
NUL, it is at LENGTH, dammit!
I like it, several such commits flew by over the last at least
weeks, and i could imagine that in a cache it also matters.

--steffen
|
|Der Kragenbaer,                The moon bear,
|der holt sich munter           he cheerfully and one by one
|einen nach dem anderen runter  wa.ks himself off
|(By Robert Gernhardt)


More information about the svn-src-all mailing list