[ruby-cvs:73514] normal:r66413 (trunk): thread_pthread.c: fix memory leak from fork loop leapfrog (v3)

normal at ruby-lang.org normal at ruby-lang.org
Sun Dec 16 16:51:09 JST 2018


normal	2018-12-16 16:51:09 +0900 (Sun, 16 Dec 2018)

  New Revision: 66413

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

  Log:
    thread_pthread.c: fix memory leak from fork loop leapfrog (v3)
    
    Constantly forking a single-threaded process in a loop leads to
    a memory leak when using POSIX timers.  This fixes the leak for
    GNU/Linux systems running glibc.
    
    v2: disarm before timer_delete
    v3: ubf_timer_arm prevents double-arming
    
    This unreverts r66291 / commit ab73ef6b7037039a05edcbf2a0c1b1108197e036
    Example Linux-only reproduction may be found in:
    
      r66290 / commit 043047a8fd5315d98eac38ddbd04ebe8db361817
    
    Note: FreeBSD 11.2 still leaks, I'm not sure why, yet.

  Modified files:
    trunk/thread_pthread.c


More information about the ruby-cvs mailing list