[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: license request for mgetgroups

From: Eric Blake
Subject: Re: license request for mgetgroups
Date: Wed, 03 Jul 2013 15:47:30 -0600
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130625 Thunderbird/17.0.7

On 05/22/2013 11:49 AM, Eric Blake wrote:
> I am trying to fix a bug in libvirt where a child process deadlocked
> because it called initgroups() in between fork and exec when the parent
> was multithreaded; it turns out that looking up group membership
> information requires a mutex, but if some other thread in the parent
> owns that mutex at the time of the fork, then the child will no longer
> have that thread around to ever release the mutex.  The solution is to
> not call initgroups, but to instead split the use of the underlying
> pieces of what initgroups does - a call to getgrouplist prior to forking
> (requires the mutex, but pre-fork is safe) and a call to setgroups after
> forking (no lookup required, therefore no mutex involved and no deadlock
> possible).  I ended up writing my own wrapper around getgrouplist, and
> only then discovered that gnulib's mgetgroups module does a better job
> at the task, except for one bit: mgetgroups is currently GPLv3 but
> libvirt wants LGPLv2+.
> Since getgrouplist is implemented in glibc as LGPLv2+, is there any
> objection to relicensing the following modules as LGPLv2+?

More than a month has elapsed with no response from Bruno.  Given
consent from all other contributors, given Bruno's historical behaviors
on earlier license requests, and given that the code is ultimately
assigned to the FSF, I've gone ahead and made these changes.  Hopefully,
we won't have any complaints that I was too hasty.

> For my argument on the xalloc-oversized module, observe that malloca.h
> (part of the LGPLv2+ malloca module) has effectively inlined the
> contents of lib/xalloc-oversized.h, so while the larger xalloc module
> will never be LGPL (it calls exit), the mere use of checking for
> oversized allocation has already been intentionally isolated for safe
> use in LGPL code.
> For my own contributions to these modules, I'm okay with relaxing to
> LGPLv2+.  I've cc'd all other contributors as tracked by gnulib.git's
> history (I'm not sure if coreutils.git would turn up any earlier authors
> from before we promoted mgetgroups from coreutils to gnulib).  I did
> track the history of xalloc-oversized changes further back from when the
> macro was part of the larger xalloc.h (pre-split contributors marked in
> '()').  Module maintainers are denoted with *.
> getgroups [LGPLv3+] => *Jim, *Eric, Bruno, Paul
> getugroups [GPLv3+] => *Jim, Eric, Paul, Bruno, Lasse
> mgetgroups [GPLv3+] => *Jim, *Eric, Bruno
> xalloc-oversized [GPLv3+] => [*all] Eric, Paul, Jim, (Bruno)

Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature

reply via email to

[Prev in Thread] Current Thread [Next in Thread]