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

int pa_stream_finish_upload ( pa_stream s  ) 

Finish the sample upload, the stream name will become the sample name. You cancel a samp le upload by issuing pa_stream_disconnect()

Definition at line 67 of file scache.c.

References PA_CONTEXT_READY, and PA_ERR_BADSTATE.

                                          {
    pa_tagstruct *t;
    uint32_t tag;

    pa_assert(s);
    pa_assert(PA_REFCNT_VALUE(s) >= 1);

    PA_CHECK_VALIDITY(s->context, s->channel_valid, PA_ERR_BADSTATE);
    PA_CHECK_VALIDITY(s->context, s->context->state == PA_CONTEXT_READY, PA_ERR_BADSTATE);

    pa_stream_ref(s);

    t = pa_tagstruct_command(s->context, PA_COMMAND_FINISH_UPLOAD_STREAM, &tag);
    pa_tagstruct_putu32(t, s->channel);
    pa_pstream_send_tagstruct(s->context->pstream, t);
    pa_pdispatch_register_reply(s->context->pdispatch, tag, DEFAULT_TIMEOUT, pa_stream_disconnect_callback, s, NULL);

    pa_stream_unref(s);
    return 0;
}


Generated by  Doxygen 1.6.0   Back to index