예제 #1
0
파일: pwd.py 프로젝트: bheller84/babble
def getpwuid(uid):
    """
    getpwuid(uid) -> (pw_name,pw_passwd,pw_uid,
                      pw_gid,pw_gecos,pw_dir,pw_shell)
    Return the password database entry for the given numeric user ID.
    See pwd.__doc__ for more on password database entries.
    """
    try:
        return struct_passwd(_posix.getpwuid(uid))
    except NullPointerException:
        raise KeyError, uid
예제 #2
0
파일: pwd.py 프로젝트: 343829084/OpenRefine
def getpwuid(uid):
    """
    getpwuid(uid) -> (pw_name,pw_passwd,pw_uid,
                      pw_gid,pw_gecos,pw_dir,pw_shell)
    Return the password database entry for the given numeric user ID.
    See pwd.__doc__ for more on password database entries.
    """
    entry = _posix.getpwuid(uid)
    if not entry:
        raise KeyError(uid)
    return struct_passwd(entry)
예제 #3
0
def getpwuid(uid):
    """
    getpwuid(uid) -> (pw_name,pw_passwd,pw_uid,
                      pw_gid,pw_gecos,pw_dir,pw_shell)
    Return the password database entry for the given numeric user ID.
    See pwd.__doc__ for more on password database entries.
    """
    try:
        return struct_passwd(_posix.getpwuid(uid))
    except NullPointerException:
        raise KeyError, uid
예제 #4
0
def getpwuid(uid):
    """
    getpwuid(uid) -> (pw_name,pw_passwd,pw_uid,
                      pw_gid,pw_gecos,pw_dir,pw_shell)
    Return the password database entry for the given numeric user ID.
    See pwd.__doc__ for more on password database entries.
    """
    entry = _posix.getpwuid(uid)
    if not entry:
        raise KeyError(uid)
    return struct_passwd(entry)