Commit 5858f0fc authored by Mirsal Ennaime's avatar Mirsal Ennaime

UPnP services discovery: fix remaining bugs

parent 24d02d8c
...@@ -28,7 +28,6 @@ ...@@ -28,7 +28,6 @@
/* /*
\TODO: Debug messages: "__FILE__, __LINE__" ok ???, Wrn/Err ??? \TODO: Debug messages: "__FILE__, __LINE__" ok ???, Wrn/Err ???
\TODO: Change names to VLC standard ??? \TODO: Change names to VLC standard ???
\TODO: Rewrite this using the new service discovery API (see sap.c, shout.c).
*/ */
...@@ -288,7 +287,8 @@ static int Open( vlc_object_t *p_this ) ...@@ -288,7 +287,8 @@ static int Open( vlc_object_t *p_this )
services_discovery_sys_t *p_sys = ( services_discovery_sys_t * ) services_discovery_sys_t *p_sys = ( services_discovery_sys_t * )
calloc( 1, sizeof( services_discovery_sys_t ) ); calloc( 1, sizeof( services_discovery_sys_t ) );
p_sd->p_sys = p_sys; if(!(p_sd->p_sys = p_sys))
return VLC_ENOMEM;
services_discovery_SetLocalizedName( p_sd, _("UPnP devices") ); services_discovery_SetLocalizedName( p_sd, _("UPnP devices") );
...@@ -302,7 +302,7 @@ static int Open( vlc_object_t *p_this ) ...@@ -302,7 +302,7 @@ static int Open( vlc_object_t *p_this )
p_sys->serverList = new MediaServerList( p_sd ); p_sys->serverList = new MediaServerList( p_sd );
p_sys->callbackLock = new Lockable(); p_sys->callbackLock = new Lockable();
res = UpnpRegisterClient( Callback, p_sys, &p_sys->clientHandle ); res = UpnpRegisterClient( Callback, p_sd, &p_sys->clientHandle );
if( res != UPNP_E_SUCCESS ) if( res != UPNP_E_SUCCESS )
{ {
msg_Err( p_sd, "%s", UpnpGetErrorMessage( res ) ); msg_Err( p_sd, "%s", UpnpGetErrorMessage( res ) );
...@@ -1068,7 +1068,6 @@ bool MediaServerList::addServer( MediaServer* s ) ...@@ -1068,7 +1068,6 @@ bool MediaServerList::addServer( MediaServer* s )
s->getFriendlyName() ); s->getFriendlyName() );
services_discovery_t* p_sd = _p_sd; services_discovery_t* p_sd = _p_sd;
p_input_item = input_item_New( p_sd, "vlc://nop", s->getFriendlyName() ); p_input_item = input_item_New( p_sd, "vlc://nop", s->getFriendlyName() );
s->setInputItem( p_input_item ); s->setInputItem( p_input_item );
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment