Add a FIXME 0.11. Make the log message a bit more detailed and add comments.

This commit is contained in:
Stefan Kost 2009-02-02 18:05:42 +02:00
parent 0ea2afee42
commit 486fe43cb9
2 changed files with 6 additions and 2 deletions

View file

@ -237,9 +237,11 @@ audioringbuffer_thread_func (GstRingBuffer * buf)
GST_LOG_OBJECT (sink, "transfered %d bytes of %d from segment %d",
written, left, readseg);
if (written < 0 || written > left) {
/* might not be critical, it e.g. happens when aborting playback */
GST_WARNING_OBJECT (sink,
"error writing data (reason: %s), skipping segment",
g_strerror (errno));
"error writing data in %s (reason: %s), skipping segment (left: %d, written: %d)",
GST_DEBUG_FUNCPTR_NAME (writefunc),
(errno > 1 ? g_strerror (errno) : "unknown"), left, written);
break;
}
left -= written;

View file

@ -83,6 +83,8 @@ struct _GstAudioSinkClass {
/* close the device */
gboolean (*close) (GstAudioSink *sink);
/* write samples to the device */
/* FIXME 0.11: change return value to gint, as most implementation use that
* already anyway */
guint (*write) (GstAudioSink *sink, gpointer data, guint length);
/* get number of samples queued in the device */
guint (*delay) (GstAudioSink *sink);