DragonFly-2.3.0.646.g787d3 master lib/libc/gen popen.c

Peter Avalos pavalos at crater.dragonflybsd.org
Tue Apr 7 00:14:30 PDT 2009


commit 787d3afaff5c9a5a75fbda3f85d79a03124094b4
Author: Peter Avalos <pavalos at theshell.com>
Date:   Sat Mar 14 17:32:32 2009 -1000

    Sync popen(3) with FreeBSD:
    
    * Convert popen()'s `pidlist' to a SLIST, for consistency.
    
    * Protect pidlist with a mutex to avoid a race causing a duplicate
    free() when the same pipe FILE is pclosed()'d in different threads,
    and to avoid corrupting the linked list when adding or removing
    items.

Summary of changes:
 lib/libc/gen/popen.c |   63 ++++++++++++++++++++++++++++++-------------------
 1 files changed, 38 insertions(+), 25 deletions(-)

http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/787d3afaff5c9a5a75fbda3f85d79a03124094b4


-- 
DragonFly BSD source repository





More information about the Commits mailing list