|
From: <ren...@us...> - 2007-09-03 20:14:13
|
Revision: 844
http://gmyth.svn.sourceforge.net/gmyth/?rev=844&view=rev
Author: renatofilho
Date: 2007-09-03 13:14:14 -0700 (Mon, 03 Sep 2007)
Log Message:
-----------
fixed livetv destructor
Modified Paths:
--------------
trunk/gmyth/src/gmyth_livetv.c
Modified: trunk/gmyth/src/gmyth_livetv.c
===================================================================
--- trunk/gmyth/src/gmyth_livetv.c 2007-08-31 17:31:09 UTC (rev 843)
+++ trunk/gmyth/src/gmyth_livetv.c 2007-09-03 20:14:14 UTC (rev 844)
@@ -391,7 +391,7 @@
* @return <code>true</code> if the LiveTV's recorder instance configuration
* had been concluded succcesfully
*/
-static gboolean
+static gboolean
gmyth_livetv_setup_recorder_channel_name(GMythLiveTV * livetv,
gchar * channel)
{
@@ -399,6 +399,8 @@
g_return_val_if_fail(livetv != NULL, FALSE);
+ g_mutex_lock(livetv->mutex);
+
if (livetv->socket == NULL) {
livetv->socket = gmyth_socket_new();
/*
@@ -417,8 +419,6 @@
}
}
- g_mutex_lock(livetv->mutex);
-
livetv->is_livetv = TRUE;
livetv->local_hostname = gmyth_socket_get_local_hostname();
@@ -865,18 +865,18 @@
* @return the actual GMythFileTransfer instance, generated using the
* data got from the actual program info.
*/
-GMythFile *
+GMythFile*
gmyth_livetv_create_file_transfer(GMythLiveTV * livetv)
{
// GMythURI* uri = NULL;
if (NULL == livetv)
- goto done;
+ return NULL;
if (!livetv->setup_done) {
gmyth_debug
("Error: You must do the LiveTV setup, just before generating the FileTransfer from LiveTV source!");
- goto done;
+ return NULL;
}
if (livetv->proginfo != NULL)
@@ -936,19 +936,9 @@
g_object_ref(livetv->file);
+done:
g_mutex_unlock(livetv->mutex);
-
- /*
- * Do some locking procedure with the Monitor Handler messages...
- */
-
- done:
- /*
- * if ( uri != NULL ) { g_object_unref( uri ); uri = NULL; }
- */
-
return livetv->file;
-
}
/**
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|