[ruby-cvs:64151] shugo:r56985 (trunk): Don't insert an entry to loading_tbl if another thread succeed to load.

shugo at ruby-lang.org shugo at ruby-lang.org
Mon Dec 5 20:10:05 JST 2016


shugo	2016-12-05 20:10:05 +0900 (Mon, 05 Dec 2016)

  New Revision: 56985

  https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=56985

  Log:
    Don't insert an entry to loading_tbl if another thread succeed to load.
    
    If rb_thread_shield_wait() returns Qfalse, the file has been successfully
    loaded by another thread, so there is no need to insert a new entry into
    loading_tbl.  [ruby-core:78464] [Bug #12999]

  Modified files:
    trunk/load.c
    trunk/test/ruby/test_require.rb


More information about the ruby-cvs mailing list