Logo Search packages:      
Sourcecode: avahi version File versions

int avahi_simple_poll_iterate ( AvahiSimplePoll s,
int  sleep_time 

Run a single main loop iteration of this main loop. If sleep_time is < 0 this will block until any of the registered events happens, then it will execute the attached callback function. If sleep_time is 0 the routine just checks if any event is pending. If yes the attached callback function is called, otherwise the function returns immediately. If sleep_time > 0 the function will block for at most the specified time in msecs. Returns -1 on error, 0 on success and 1 if a quit request has been scheduled. Usually this function should be called in a loop until it returns a non-zero value

Definition at line 588 of file simple-watch.c.

    int r;

    if ((r = avahi_simple_poll_prepare(s, timeout)) != 0)
        return r;

    if ((r = avahi_simple_poll_run(s)) != 0)
        return r;

    if ((r = avahi_simple_poll_dispatch(s)) != 0)
        return r;
    return 0;

Generated by  Doxygen 1.6.0   Back to index