Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 01 May 2015 13:10:14 -0700
From:      Xin Li <delphij@delphij.net>
To:        Baptiste Daroussin <bapt@freebsd.org>,  Sergey Kandaurov <pluknet@freebsd.org>
Cc:        svn-src-head@freebsd.org, svn-src-all@freebsd.org,  src-committers@freebsd.org
Subject:   Re: svn commit: r282314 - in head: include lib/libc/stdlib
Message-ID:  <5543DDA6.6080702@delphij.net>
In-Reply-To: <20150501193407.GT13141@ivaldir.etoilebsd.net>
References:  <201505011832.t41IWGSs002284@svn.freebsd.org> <CAE-mSOLBYgghng-hdbvK0_Eyn4m8RghkR3ea7E=jVNjdimYcRA@mail.gmail.com> <20150501193407.GT13141@ivaldir.etoilebsd.net>

next in thread | previous in thread | raw e-mail | index | archive | help
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512

On 05/01/15 12:34, Baptiste Daroussin wrote:
> On Fri, May 01, 2015 at 10:22:50PM +0300, Sergey Kandaurov wrote:
>> On 1 May 2015 at 21:32, Baptiste Daroussin <bapt@freebsd.org>
>> wrote:
>>> Author: bapt Date: Fri May  1 18:32:16 2015 New Revision:
>>> 282314 URL: https://svnweb.freebsd.org/changeset/base/282314
>>> 
>>> Log: Import reallocarray(3) from OpenBSD
>>> 
>>> Add a manpage for it, assign the copyright to the OpenBSD
>>> project on it since it is mostly copy/paste from OpenBSD
>>> manpage. style(9) fixes [..]
>> 
>>> Added: head/lib/libc/stdlib/reallocarray.3 
>>> ====================================================================
==========
>>>
>>> 
- --- /dev/null   00:00:00 1970   (empty, because file is newly added)
>>> +++ head/lib/libc/stdlib/reallocarray.3 Fri May  1 18:32:16
>>> 2015        (r282314) @@ -0,0 +1,136 @@ +.\" Copyright (c) 2015
>>> OpenBSD +.\" All rights reserved.
>> 
>> This copyright notice looks suspicious.
>> 
> Well I wrote the man page but by copy/pasting code from OpenBSD
> malloc(3) manpage which copyright should I set?

"OpenBSD" is not a legal entity so the declaration _may_ be invalid
(IANL).  OpenBSD developers are very careful here, and there is no
reason we should do the opposite.

Normally you copy the copyright notice altogether (in this case, since
the text are mostly new creation from Theo de Raadt, he may have the
right to just license this portion to us; they probably didn't do it
because the new addition to the malloc(3) manual page is too small to
warrant additional owners) or rewrite it to make the copyright
ownership clear.

I'm kinda disappointed with the fact that there is no seek for public
review (e.g. -arch@ or -standard@) on wider audience level for
essential system libraries like libc, as others may already working on
this in private, by the way.  But since the API is already there I
guess it should stay.

Two comments on the code change itself:

a) __FreeBSD_version should be bumped and this should be documented.

b) It may be sensible to use __builtin_umul_overflow instead of
hand-rolling the same functionality.  I think the compiler is not
smart enough to handle that.

Cheers,
- -- 
Xin LI <delphij@delphij.net>    https://www.delphij.net/
FreeBSD - The Power to Serve!           Live free or die
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.1.2 (FreeBSD)

iQIcBAEBCgAGBQJVQ92iAAoJEJW2GBstM+nsBv4P/RadRIHMLOrhlh+31/1Ydwf+
Wv3pQ6SGCDU88Tiqwf0WuuIrMzihyTLMk1AJ6B6uYgV+AEo1dXeCGSfW7aTRgebc
oJzxfG/42XvJcZI0SZVIEmGCOOezjkNF0yvx7xJkH7Lqs+wlpTN4nsuROyKlB3K+
8zYkVIG4SPMZtZRgJbXCdB9/loEETjpCj52Fbku/n+zTKBcraeUiKIliHAhjQOV0
S9Q/+WjpjmK1WukZAn3QB+0abCrsJoHlQNZ/wL6f6IpIilxHJ7oebtgnY3UbzJie
nxbPfLDGR2G4n9nZp6sftaSQnIbFiLG20Bs3lWhjXoP0nN05xG3nT9Q5Y7AL/TLZ
KLq9phaROT3ssAlxwGEoDXS5aEQIs8LrPs4xLIVtazHAr9bQz8uA3VM/y6a3XDqv
u0JreETjyWNNuA27T/Zx8g7/V9+sOVxygtB+MWj7HQocqMw6GBpFs+LoprgyJ76W
/7xUqZ8qW7l/Fk1mqgybtxfLckjAdiqgHEWXHeGZHeaJ0smKU+IsPq0PcTD9MDQG
CLTDAbkEtfKIm6BHVWwqk8EuEL+yYB1qmXHlx/ejuKZWgBHHZYHDCBN0zbGK868x
DMmjzOZDQBH19rCEHemdy945v+SngqSheLLnUQlNnfzuQ4ccTtn+V7fqQDiH1txT
KnL/1PZlEWdtSH2bhK+t
=HGeH
-----END PGP SIGNATURE-----



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?5543DDA6.6080702>