]> git.sesse.net Git - vlc/blobdiff - src/misc/messages.c
Don't leak every https parameters.
[vlc] / src / misc / messages.c
index f00a1de1ed6e32b4b786aa847d217a328384a2f4..be832c65c87fba5ec3ea54be0cd2c8e3768f2059 100644 (file)
@@ -78,11 +78,6 @@ static void QueueMsg ( vlc_object_t *, int, const char *,
 static void FlushMsg ( msg_queue_t * );
 static void PrintMsg ( vlc_object_t *, msg_item_t * );
 
-static inline char * object_description( vlc_object_t * p_this )
-{
-    return strdup( p_this->psz_object_type );
-}
-
 /**
  * Initialize messages queues
  * This function initializes all message queues
@@ -427,7 +422,7 @@ static void QueueMsg( vlc_object_t *p_this, int i_type, const char *psz_module,
 
             p_item->i_type =        VLC_MSG_WARN;
             p_item->i_object_id =   p_this->i_object_id;
-            p_item->psz_object =    object_description( p_this );
+            p_item->psz_object_type = p_this->psz_object_type;
             p_item->psz_module =    strdup( "message" );
             p_item->psz_msg =       strdup( "message queue overflowed" );
             p_item->psz_header =    NULL;
@@ -448,7 +443,7 @@ static void QueueMsg( vlc_object_t *p_this, int i_type, const char *psz_module,
     /* Fill message information fields */
     p_item->i_type =        i_type;
     p_item->i_object_id =   p_this->i_object_id;
-    p_item->psz_object =    object_description( p_this );
+    p_item->psz_object_type = p_this->psz_object_type;
     p_item->psz_module =    strdup( psz_module );
     p_item->psz_msg =       psz_str;
     p_item->psz_header =    psz_header;
@@ -460,7 +455,6 @@ static void QueueMsg( vlc_object_t *p_this, int i_type, const char *psz_module,
         free( p_item->psz_module );
         free( p_item->psz_msg );
         free( p_item->psz_header );
-        free( p_item->psz_object );
     }
 
     vlc_mutex_unlock ( &p_queue->lock );
@@ -506,7 +500,6 @@ static void FlushMsg ( msg_queue_t *p_queue )
         free( p_queue->msg[i_index].psz_msg );
         free( p_queue->msg[i_index].psz_module );
         free( p_queue->msg[i_index].psz_header );
-        free( p_queue->msg[i_index].psz_object );
     }
 
     /* Update the new start value */
@@ -552,7 +545,7 @@ static void PrintMsg ( vlc_object_t * p_this, msg_item_t * p_item )
             break;
     }
 
-    psz_object = p_item->psz_object;
+    psz_object = p_item->psz_object_type;
 
 #ifdef UNDER_CE
 #   define CE_WRITE(str) WriteFile( QUEUE.logfile, \