Err ssplAbort ( SoundSpooler *sspl, void(*UserBufferProcessor) ( SoundSpooler *,SoundBufferNode * ) )
ssplAbort()
stops the spooler (by calling ssplStopSpooler()
) and removes all buffers in the active queue (by calling ssplReset()
) , including the one currently being played.
If a SoundBufferFunc is installed, a SSPL_SBMSG_ABORT message is sent to it with each SoundBufferNode removed from the active queue. If UserBufferProcessor is non-NULL, each SoundBufferNode removed from the active queue is passed to it. If both a SoundBufferFunc and UserBufferProcessor are supplied, ssplAbort()
fails and returns ML_ERR_BAD_ARG.
If SoundBufferFunc fails, ssplAbort()
fails immediately and returns the error code returned by SoundBufferFunc without removing the rest of the buffers from the active queue. Calling ssplAbort()
again safely picks up where it left off.
Clears SSPL_STATUS_F_STARED, SSPL_STATUS_F_PAUSED, and SSPL_STATUS_F_ACTIVE.
ssplStopSpooler
(), ssplSendBuffer(), ssplProcessSignals(), ssplReset(), SoundBufferFunc(), UserBufferProcessor() ssplGetSpoolerStatus()