+2006-06-02 Michael Smith <msmith@fluendo.com>
+
+ * libs/gst/check/gstcheck.c: (gst_check_init),
+ (gst_check_chain_func):
+ * libs/gst/check/gstcheck.h:
+ Add a cond/mutex to the check support lib, signal this whenever we
+ add to the buffers list. This will allow tests to not busy-wait on
+ the buffer-list.
+
2006-06-02 Thomas Vander Stichele <thomas at apestaart dot org>
* libs/gst/dataprotocol/dataprotocol.c:
gst_check_log_critical_func, NULL);
g_log_set_handler ("GLib-GObject", G_LOG_LEVEL_CRITICAL | G_LOG_LEVEL_WARNING,
gst_check_log_critical_func, NULL);
+
+ check_cond = g_cond_new ();
+ check_mutex = g_mutex_new ();
}
/* message checking */
GST_DEBUG ("chain_func: received buffer %p", buffer);
buffers = g_list_append (buffers, buffer);
+ g_mutex_lock (check_mutex);
+ g_cond_signal (check_cond);
+ g_mutex_unlock (check_mutex);
+
return GST_FLOW_OK;
}
/* global variables used in test methods */
GList * buffers;
+GMutex *check_mutex;
+GCond *check_cond;
+
void gst_check_init (int *argc, char **argv[]);
GstFlowReturn gst_check_chain_func (GstPad *pad, GstBuffer *buffer);