]> git.sesse.net Git - vlc/commitdiff
Set object name from module_need()
authorRémi Denis-Courmont <remi@remlab.net>
Sun, 20 Sep 2009 09:43:20 +0000 (12:43 +0300)
committerRémi Denis-Courmont <remi@remlab.net>
Sun, 20 Sep 2009 09:48:37 +0000 (12:48 +0300)
src/libvlc.c
src/modules/modules.c

index 6d3eb82ad1c793db8e457b3deca5f3b7cca4469d..efebc02bde24f46ac5fe9c653f1c6bc3f54fe1b2 100644 (file)
@@ -782,6 +782,8 @@ int libvlc_InternalInit( libvlc_int_t *p_libvlc, int i_argc,
      * Choose the best memcpy module
      */
     priv->p_memcpy_module = module_need( p_libvlc, "memcpy", "$memcpy", false );
+    /* Avoid being called "memcpy":*/
+    vlc_object_set_name( p_libvlc, "main" );
 
     priv->b_stats = config_GetInt( p_libvlc, "stats" ) > 0;
     priv->i_timers = 0;
index cadfd6235c39f57fb1830f795a34f5eec6c84c27..d9aedc478ce5bba4c77bc6aaabed481cfb11785e 100644 (file)
@@ -605,6 +605,8 @@ found_shortcut:
     {
         msg_Dbg( p_this, "using %s module \"%s\"",
                  psz_capability, p_module->psz_object_name );
+        vlc_object_set_name( p_this, psz_alias ? psz_alias
+                                               : p_module->psz_object_name );
     }
     else if( count == 0 )
     {