vlc | branch: master | Hugo Beauzée-Luyssen <[email protected]> | Fri Jun 26 16:02:31 2020 +0200| [dd42cbe65db17f2a2e39a273a8a9a0b0fd9a06ac] | committer: Hugo Beauzée-Luyssen
microdns: Include the model in the item name This can help differenciate devices with similar names and matches bonjour's behavior > http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=dd42cbe65db17f2a2e39a273a8a9a0b0fd9a06ac --- modules/services_discovery/microdns.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/modules/services_discovery/microdns.c b/modules/services_discovery/microdns.c index 3cbd501681..16f23d914c 100644 --- a/modules/services_discovery/microdns.c +++ b/modules/services_discovery/microdns.c @@ -521,6 +521,16 @@ new_entries_rd_cb( void *p_this, int i_status, const struct rr_entry *p_entries free( psz_uri ); break; } + if( p_srv->renderer.psz_model != NULL ) + { + char* psz_name; + if ( asprintf( &psz_name, "%s (%s)", p_srv->psz_device_name, + p_srv->renderer.psz_model ) > 0 ) + { + free( p_srv->psz_device_name ); + p_srv->psz_device_name = psz_name; + } + } if( strcmp( p_srv->psz_protocol, "chromecast" ) == 0) psz_demux_filter = "cc_demux"; _______________________________________________ vlc-commits mailing list [email protected] https://mailman.videolan.org/listinfo/vlc-commits
