docs: convert NULL, TRUE, and FALSE to %NULL, %TRUE, and %FALSE
[platform/upstream/gstreamer.git] / gst / gsttask.c
index 2c385ed..b562f6c 100644 (file)
@@ -16,8 +16,8 @@
  *
  * You should have received a copy of the GNU Library General Public
  * License along with this library; if not, write to the
- * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
- * Boston, MA 02111-1307, USA.
+ * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
  */
 
 /**
@@ -38,7 +38,7 @@
  * might sometimes be needed to create a #GstTask manually if it is not related to
  * a #GstPad.
  *
- * Before the #GstTask can be run, it needs a #GStaticRecMutex that can be set with
+ * Before the #GstTask can be run, it needs a #GRecMutex that can be set with
  * gst_task_set_lock().
  *
  * The task can be started, paused and stopped with gst_task_start(), gst_task_pause()
@@ -64,8 +64,6 @@
  * name on Linux. Please note that the object name should be configured before the
  * task is started; changing the object name after the task has been started, has
  * no effect on the thread name.
- *
- * Last reviewed on 2012-03-29 (0.11.3)
  */
 
 #include "gst_private.h"
@@ -197,6 +195,9 @@ gst_task_init (GstTask * task)
   g_mutex_lock (&pool_lock);
   task->priv->pool = gst_object_ref (klass->pool);
   g_mutex_unlock (&pool_lock);
+
+  /* clear floating flag */
+  gst_object_ref_sink (task);
 }
 
 static void
@@ -330,7 +331,7 @@ exit:
     GST_OBJECT_LOCK (task);
   }
   /* now we allow messing with the lock again by setting the running flag to
-   * FALSE. Together with the SIGNAL this is the sign for the _join() to
+   * %FALSE. Together with the SIGNAL this is the sign for the _join() to
    * complete.
    * Note that we still have not dropped the final ref on the task. We could
    * check here if there is a pending join() going on and drop the last ref
@@ -386,7 +387,7 @@ gst_task_cleanup_all (void)
  * This function will not yet create and start a thread. Use gst_task_start() or
  * gst_task_pause() to create and start the GThread.
  *
- * Before the task can be used, a #GStaticRecMutex must be configured using the
+ * Before the task can be used, a #GRecMutex must be configured using the
  * gst_task_set_lock() function. This lock will always be acquired while
  * @func is called.
  *
@@ -453,8 +454,6 @@ is_running:
  *
  * Returns: (transfer full): the #GstTaskPool used by @task. gst_object_unref()
  * after usage.
- *
- * Since: 0.10.24
  */
 GstTaskPool *
 gst_task_get_pool (GstTask * task)
@@ -482,8 +481,6 @@ gst_task_get_pool (GstTask * task)
  * will be created by @task will now use @pool.
  *
  * MT safe.
- *
- * Since: 0.10.24
  */
 void
 gst_task_set_pool (GstTask * task, GstTaskPool * pool)
@@ -654,8 +651,6 @@ start_task (GstTask * task)
  * MT safe.
  *
  * Returns: %TRUE if the state could be changed.
- *
- * Since: 0.10.24
  */
 gboolean
 gst_task_set_state (GstTask * task, GstTaskState state)