[vlc-devel] [PATCH 3/3] upnp: rename module callbacks to be more verbose

Shaleen Jain shaleen at jain.sh
Mon Jun 25 15:49:12 CEST 2018


---
 modules/services_discovery/upnp.cpp | 20 ++++++++++----------
 1 file changed, 10 insertions(+), 10 deletions(-)

diff --git a/modules/services_discovery/upnp.cpp b/modules/services_discovery/upnp.cpp
index 26d9206b5f..f4dbadede4 100644
--- a/modules/services_discovery/upnp.cpp
+++ b/modules/services_discovery/upnp.cpp
@@ -75,14 +75,14 @@ struct access_sys_t
  */
 namespace SD
 {
-    static int Open( vlc_object_t* );
-    static void Close( vlc_object_t* );
+    static int OpenSD( vlc_object_t* );
+    static void CloseSD( vlc_object_t* );
 }
 
 namespace Access
 {
-    static int Open( vlc_object_t* );
-    static void Close( vlc_object_t* );
+    static int OpenAccess( vlc_object_t* );
+    static void CloseAccess( vlc_object_t* );
 }
 
 VLC_SD_PROBE_HELPER( "upnp", N_("Universal Plug'n'Play"), SD_CAT_LAN )
@@ -96,7 +96,7 @@ vlc_module_begin()
     set_category( CAT_PLAYLIST );
     set_subcategory( SUBCAT_PLAYLIST_SD );
     set_capability( "services_discovery", 0 );
-    set_callbacks( SD::Open, SD::Close );
+    set_callbacks( SD::OpenSD, SD::CloseSD );
 
     add_string( "satip-channelist", "ASTRA_19_2E", SATIP_CHANNEL_LIST,
                 SATIP_CHANNEL_LIST, false )
@@ -107,7 +107,7 @@ vlc_module_begin()
     add_submodule()
         set_category( CAT_INPUT )
         set_subcategory( SUBCAT_INPUT_ACCESS )
-        set_callbacks( Access::Open, Access::Close )
+        set_callbacks( Access::OpenAccess, Access::CloseAccess )
         set_capability( "access", 0 )
 
     VLC_SD_PROBE_SUBMODULE
@@ -195,7 +195,7 @@ SearchThread( void *p_data )
 /*
  * Initializes UPNP instance.
  */
-static int Open( vlc_object_t *p_this )
+static int OpenSD( vlc_object_t *p_this )
 {
     services_discovery_t *p_sd = ( services_discovery_t* )p_this;
     services_discovery_sys_t *p_sys  = ( services_discovery_sys_t * )
@@ -239,7 +239,7 @@ static int Open( vlc_object_t *p_this )
 /*
  * Releases resources.
  */
-static void Close( vlc_object_t *p_this )
+static void CloseSD( vlc_object_t *p_this )
 {
     services_discovery_t *p_sd = ( services_discovery_t* )p_this;
     services_discovery_sys_t *p_sys = reinterpret_cast<services_discovery_sys_t *>( p_sd->p_sys );
@@ -1226,7 +1226,7 @@ static int ReadDirectory( stream_t *p_access, input_item_node_t* p_node )
     return VLC_SUCCESS;
 }
 
-static int Open( vlc_object_t *p_this )
+static int OpenAccess( vlc_object_t *p_this )
 {
     stream_t* p_access = (stream_t*)p_this;
     access_sys_t* p_sys = new(std::nothrow) access_sys_t;
@@ -1247,7 +1247,7 @@ static int Open( vlc_object_t *p_this )
     return VLC_SUCCESS;
 }
 
-static void Close( vlc_object_t* p_this )
+static void CloseAccess( vlc_object_t* p_this )
 {
     stream_t* p_access = (stream_t*)p_this;
     access_sys_t *sys = (access_sys_t *)p_access->p_sys;
-- 
2.18.0


More information about the vlc-devel mailing list