[OE-core] [PATCH 1/1] useradd_base.bbclass: fix simultaneous with flock

Burton, Ross ross.burton at intel.com
Tue Feb 16 12:09:43 UTC 2016


On 16 February 2016 at 07:14, <kai.kang at windriver.com> wrote:

> +FLOCK_FILE=$SYSROOT/etc
>

useradd_base is also used by extrausers.bbclass, so it would be best if
useradd_base decided where to use as a lock ($rootdir/${sysconfdir} sounds
sensible) instead of expecting that the caller sets FLOCK_FILE and
mysteriously failing if it wasn't set.

Also if we're locking and waiting properly instead of using timeouts and
loops, can we remove the "does it exist?" check before the operation (eg
groupadd -f will exit 0 if the group exists) and after (with proper locking
that shouldn't be happening).

Ross
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openembedded.org/pipermail/openembedded-core/attachments/20160216/34ab6369/attachment-0002.html>


More information about the Openembedded-core mailing list