keystoneclient/common/cms.py
def _process_communicate_handle_oserror(process, data, files):
    """Wrapper around process.communicate that checks for OSError."""

    try:
        output, err = process.communicate(data)
    except OSError as e:
        if e.errno != errno.EPIPE:
            raise
        # OSError with EPIPE only occurs with Python 2.6.x/old 2.7.x
        # http://bugs.python.org/issue10963

        # The quick exit is typically caused by the openssl command not being
        # able to read an input file, so check ourselves if can't read a file.
        retcode, err = _check_files_accessible(files)
        if process.stderr:
            msg = process.stderr.read()
            err = err + msg.decode('utf-8')
        output = ''
    else:
        retcode = process.poll()
        if err is not None:
            err = err.decode('utf-8')

    return output, err, retcode
Wrapper around process.communicate that checks for OSError.
Wrapper around process.communicate that checks for OSError.
Wrapper around process . communicate that checks for OSError .
def _process_communicate_handle_oserror(process, data, files):
    try:
        output, err = process.communicate(data)
    except OSError as e:
        if e.errno != errno.EPIPE:
            raise
        retcode, err = _check_files_accessible(files)
        if process.stderr:
            msg = process.stderr.read()
            err = err + msg.decode('utf-8')
        output = ''
    else:
        retcode = process.poll()
        if err is not None:
            err = err.decode('utf-8')
    return output, err, retcode
def _process_communicate_handle_oserror ( process , data , files ) : try : output , err = process . communicate ( data ) except OSError as e : if e . errno != errno . EPIPE : raise retcode , err = _check_files_accessible ( files ) if process . stderr : msg = process . stderr . read ( ) err = err + msg . decode ( 'utf-8' ) output = '' else : retcode = process . poll ( ) if err is not None : err = err . decode ( 'utf-8' ) return output , err , retcode
Wrapper around process.communicate that checks for OSError.
Wrapper around process . communicate that checks for OSError .
"""Wrapper around process.communicate that checks for OSError.""" # OSError with EPIPE only occurs with Python 2.6.x/old 2.7.x # http://bugs.python.org/issue10963 # The quick exit is typically caused by the openssl command not being # able to read an input file, so check ourselves if can't read a file.
process
data
files