OpenAFS Master Repository branch, master, updated. openafs-devel-1_5_72-39-g45aceee

Gerrit Code Review gerrit@openafs.org
Mon, 22 Feb 2010 09:21:37 -0800 (PST)


The following commit has been merged in the master branch:
commit 45aceee9842265fb0ccdb5e8f3f6d32c8d2b99ea
Author: Andrew Deason <adeason@sinenomine.net>
Date:   Mon Feb 15 10:55:33 2010 -0600

    h_TossStuff_r: check held-ness after lock
    
    h_TossStuff_r checks if a host is held or locked by another thread
    before trying to delete the host. Unfortunately, it checks if it is
    locked before checking if it is held, and the lock check drops H_LOCK.
    Thus, another thread could hold the host while we don't have H_LOCK, and
    we could delete a host that is being held.
    
    Although it is a bug if any thread holds a host that is being deleted,
    some instances of this still exist, so make the check more robust.
    Reverse the order of the tests, so we detect if someone held the host
    while the lock check dropped H_LOCK.
    
    Also log when this happens, as it indicates a bug occurring.
    
    FIXES 126454
    
    Change-Id: I8fa972c430e63fc46ca4fadcc3429173ac91a947
    Reviewed-on: http://gerrit.openafs.org/1312
    Tested-by: Andrew Deason <adeason@sinenomine.net>
    Reviewed-by: Alistair Ferguson <alistair.ferguson@mac.com>
    Reviewed-by: Derrick Brashear <shadow@dementia.org>
    Tested-by: Derrick Brashear <shadow@dementia.org>

 src/viced/host.c |   15 +++++++++++----
 1 files changed, 11 insertions(+), 4 deletions(-)

-- 
OpenAFS Master Repository