]> git.sesse.net Git - vlc/blobdiff - src/control/media_discoverer.c
Move LibVLC error messages to libvlc_printerr().
[vlc] / src / control / media_discoverer.c
index e7f479ea37cd3bbe71cfe40d4903ff3babda0146..e4482de9e595ab59b22df7c20717366280eb2d72 100644 (file)
@@ -178,7 +178,8 @@ libvlc_media_discoverer_new_from_name( libvlc_instance_t * p_inst,
     p_mdis = malloc(sizeof(libvlc_media_discoverer_t));
     if( !p_mdis )
     {
-        libvlc_exception_raise( p_e, "Not enough memory" );
+        libvlc_exception_raise( p_e );
+        libvlc_printerr( "Not enough memory" );
         return NULL;
     }
 
@@ -202,7 +203,8 @@ libvlc_media_discoverer_new_from_name( libvlc_instance_t * p_inst,
     if( !p_mdis->p_sd )
     {
         libvlc_media_list_release( p_mdis->p_mlist );
-        libvlc_exception_raise( p_e, "Can't find the services_discovery module named '%s'", psz_name );
+        libvlc_exception_raise( p_e );
+        libvlc_printerr( "%s: no such discovery module found", psz_name );
         free( p_mdis );
         return NULL;
     }
@@ -228,7 +230,8 @@ libvlc_media_discoverer_new_from_name( libvlc_instance_t * p_inst,
     if( !vlc_sd_Start( p_mdis->p_sd, psz_name ) )
     {
         libvlc_media_list_release( p_mdis->p_mlist );
-        libvlc_exception_raise( p_e, "Can't start the services_discovery module named '%s'", psz_name );
+        libvlc_exception_raise( p_e );
+        libvlc_printerr( "%s: internal module error", psz_name );
         free( p_mdis );
         return NULL;
     }