Beispiel #1
0
static void
coreconsole_io_func(void* opaque, int fd, unsigned events)
{
    CoreConsole* cc = opaque;
    AsyncStatus  status;
    status = asyncConsoleConnector_run(cc->connector, cc->io);
    if (status == ASYNC_COMPLETE) {
        cc->ok = 1;
    }
}
Beispiel #2
0
AsyncStatus
asyncConsoleConnector_connect(AsyncConsoleConnector* acc,
                              const SockAddress*     address,
                              LoopIo*                io)
{
    acc->state = STATE_INITIAL;
    acc->address = address[0];
    acc->io = io;
    return asyncConsoleConnector_run(acc);
}