def read_sock(sock):
    buffers = []
    while True:
        try:
            buffer = sock.recv(BUFFER_SIZE)
        except __HOLE__ as err:
            if err.errno != errno.EINTR:
                raise
            continue
        else:
            if not buffer:
                break
            buffers.append(buffer)
    return b''.join(buffers)
dataset/ETHPy150Open serverdensity/sd-agent-plugins/Uwsgi/Uwsgi.py/read_sock