The following commit has been merged in the master branch:
commit c36a1525f13d3900817caea7dbd0c934cc93931e
Author: Andrew Deason <[email protected]>
Date:   Tue Oct 14 17:02:55 2014 -0500

    auth: Fix GetNthIdentityOrUser EOF return code
    
    Before commit 0af17e7e, afsconf_GetNthUser always returned 1 on
    failure, to indicate to the caller that they should stop traversing
    over the list. After commit 0af17e7e, when reaching the end of the
    list, we return EIO or -1. This causes 'bos listusers' invocations to
    always fail, since 'bos' clients expect to get the code 1 when
    reaching the end of the SUsers list.
    
    To fix this, make GetNthIdentityOrUser always return -1 when searching
    beyond the end of the list. For the newer interface
    afsconf_GetNthIdentity, we return this as-is, to have a separate
    return code specifically for EOF, but still allowing us to return any
    positive error code in case of an error.
    
    For the older interface afsconf_GetNthUser, return 1 in this
    situation, to retain compatibility with the old interface (both at the
    libauth level and on the wire).
    
    Change-Id: I2db4760440d7846dc290a05fa24e24ec97a02f12
    Reviewed-on: http://gerrit.openafs.org/7377
    Tested-by: BuildBot <[email protected]>
    Reviewed-by: Benjamin Kaduk <[email protected]>
    Reviewed-by: D Brashear <[email protected]>

 src/auth/userok.c |   27 ++++++++++++++++++++++-----
 1 files changed, 22 insertions(+), 5 deletions(-)

-- 
OpenAFS Master Repository
_______________________________________________
OpenAFS-cvs mailing list
[email protected]
https://lists.openafs.org/mailman/listinfo/openafs-cvs

Reply via email to