On Mon, Jan 23, 2017 at 10:52:21AM -0800, Simon J. Gerraty wrote: > Jilles Tjoelker <jilles_at_stack.nl> wrote: > > Index: etc/rc.d/random > > =================================================================== > > --- etc/rc.d/random (revision 311446) > > +++ etc/rc.d/random (working copy) > > _at__at_ -20,12 +20,14 _at__at_ > > > > save_dev_random() > > { > > + oumask=`umask` > why not simply use a sub-shell to tighten umask > (umask 077; what-ever) With our /bin/sh, the save-restore method saves a fork. A command substitution with a single umask command does not fork, while a subshell containing umask and something else does. The effect is fairly minor, but good performance is often the product of many small optimizations. -- Jilles TjoelkerReceived on Mon Jan 23 2017 - 21:11:00 UTC
This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:41:09 UTC