[ruby-core:84140] Re: getpwnam and friends + GVL

From: Eric Wong <normalperson@...>
Date: 2017-12-09 03:51:15 UTC
List: ruby-core #84140
Eric Wong <normalperson@yhbt.net> wrote:
> A lot of these functions in Etc and also used for $HOME
> resolution require opening /etc/passwd or /etc/group, so
> 
> Basically the same problem as readdir(3) I wrote about in
> http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-core/83808

Well, the _r variants of get{pw,gr}* functions are safe-to-use
and not deprecated unlike readdir_r, so we can try it some other
time (too late for 2.6, I guess).

> (My /etc/ is on a slow rotating disk)

That disk may break before I get around to making necessary code
changes; and I'll give up hacking entirely :<

Unsubscribe: <mailto:ruby-core-request@ruby-lang.org?subject=unsubscribe>
<http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-core>

In This Thread

Prev Next