Eric Wong <normalperson / yhbt.net> wrote:
> However; when reading glibc source[1], I noticed every DIR stream has
> a lock which guards readdir calls since 1996[2].
> 
> So maybe whitelist glibc (and maybe win32) implementations
> for GVL release on readdir?

No on whitelist.   Actual dirent returned by readdir can still
be clobbered despite that lock.  That glibc lock is only to protect
internal glibc structures, not dirent data the user sees.
GVL to protect readdir is probably still the best way going
forward.  We may introduce new lock(s) (while releasing GVL),
but it's too complex and late for 2.5.

> [1] git://sourceware.org/git/glibc.git - sysdeps/posix/readdir.c
> [2] commit c150923988933b5db75a974d4cc08cd7f7aaf3dc in glibc[1]

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