aio_ctx_prepare(GSource *source, gint    *timeout)

{

    AioContext *ctx = (AioContext *) source;

    uint32_t wait = -1;

    aio_bh_update_timeout(ctx, &wait);



    if (wait != -1) {

        *timeout = MIN(*timeout, wait);

        return wait == 0;

    }



    return false;

}

aio_ctx_prepare(GSource *source, gint    *timeout)

{

    AioContext *ctx = (AioContext *) source;

    uint32_t wait = -1;

    aio_bh_update_timeout(ctx, &wait);



    if (wait != -1) {

        *timeout = MIN(*timeout, wait);

        return wait == 0;

    }



    return false;

}

FUNC_0(GSource *VAR_0, gint    *VAR_1)

{

    AioContext *ctx = (AioContext *) VAR_0;

    uint32_t wait = -1;

    aio_bh_update_timeout(ctx, &wait);



    if (wait != -1) {

        *VAR_1 = MIN(*VAR_1, wait);

        return wait == 0;

    }



    return false;

}

FUNC_0(GSource *VAR_0, gint    *VAR_1)
{ AioContext *ctx = (AioContext *) VAR_0; uint32_t wait = -1; aio_bh_update_timeout(ctx, &wait); if (wait != -1) { *VAR_1 = MIN(*VAR_1, wait); return wait == 0; } return false; }