git: kernel - Fix system lockup w/ kqueue based select/poll due to dup2()

Matthew Dillon dillon at crater.dragonflybsd.org
Sat Aug 21 14:03:44 PDT 2010


commit 34e191bd0d5b8cb3e96c427a1d2f32bd96fc0aba
Author: Matthew Dillon <dillon at apollo.backplane.com>
Date:   Sat Aug 21 14:00:49 2010 -0700

    kernel - Fix system lockup w/ kqueue based select/poll due to dup2()
    
    * dup2() was not calling knote_fdclose() on the original descriptor being
      replaced
    
    * fdfree() (called by exit) was not cleaning out knotes either, though
      exit*() probably took care of it already when it closed the descriptors.
    
    * Assert that a file has no knotes on the last fdrop().
    
    Reported-by: everyone + lentferj + alexh + swildner + Studbolt

Summary of changes:
 sys/kern/kern_descrip.c |   11 +++++++++++
 sys/kern/kern_event.c   |   28 ++++++++++------------------
 2 files changed, 21 insertions(+), 18 deletions(-)

http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/34e191bd0d5b8cb3e96c427a1d2f32bd96fc0aba


-- 
DragonFly BSD source repository





More information about the Commits mailing list