Logo Search packages:      
Sourcecode: pulseaudio version File versions  Download package

int pa_context_is_local ( pa_context c  ) 

Returns 1 when the connection is to a local daemon. Returns negative when no connection has been made yet.

Definition at line 1244 of file context.c.

References PA_CONTEXT_IS_GOOD(), PA_ERR_BADSTATE, and PA_ERR_FORKED.

                                       {
    pa_assert(c);
    pa_assert(PA_REFCNT_VALUE(c) >= 1);

    PA_CHECK_VALIDITY_RETURN_ANY(c, !pa_detect_fork(), PA_ERR_FORKED, -1);
    PA_CHECK_VALIDITY_RETURN_ANY(c, PA_CONTEXT_IS_GOOD(c->state), PA_ERR_BADSTATE, -1);

    return !!c->is_local;
}


Generated by  Doxygen 1.6.0   Back to index