check/generic/states.c: Make sure all tasks are stopped.
authorWim Taymans <wim.taymans@gmail.com>
Wed, 24 Aug 2005 20:49:53 +0000 (20:49 +0000)
committerWim Taymans <wim.taymans@gmail.com>
Wed, 24 Aug 2005 20:49:53 +0000 (20:49 +0000)
commit1e40e471d9b2296470afd259656431af1940a34d
treec3ff298332f857798202cb4c47367a778ad0f0d3
parentec8ec3da8a5ec89ac661ae009e19ee198f52c62a
check/generic/states.c: Make sure all tasks are stopped.

Original commit message from CVS:
* check/generic/states.c: (GST_START_TEST):
Make sure all tasks are stopped.

* check/gst/gstbin.c: (GST_START_TEST):
Unref after usage for proper valgrinding.

* gst/gstpad.c: (gst_pad_finalize), (gst_pad_stop_task):
Really wait for the task to stop before destroying the
mutex.

* gst/gstqueue.c: (gst_queue_sink_activate_push),
(gst_queue_src_activate_push):
Small cleanups. Don't stop the task when we did not start
it.

* gst/gsttask.c: (gst_task_get_type), (gst_task_init),
(gst_task_func), (gst_task_cleanup_all), (gst_task_set_lock),
(gst_task_get_state), (gst_task_start), (gst_task_pause),
(gst_task_join):
* gst/gsttask.h:
Protect the stream lock with the object lock.
Disallow setting the stream lock when running.
Add cleanup_all to wait for the threadpool to finish.
Remove code to autoallocate a mutex if none was provided.
Add _join() to wait for a task to stop.
Protect the thread pool with a global lock.
ChangeLog
check/generic/states.c
check/gst/gstbin.c
gst/gstpad.c
gst/gstqueue.c
gst/gsttask.c
gst/gsttask.h
plugins/elements/gstqueue.c
tests/check/generic/states.c
tests/check/gst/gstbin.c