No need for sprintf() here

This reverts commit af688c8f29.
This commit is contained in:
Rémi Denis-Courmont 2010-02-10 17:38:33 +02:00
parent 4f4a8d71bb
commit ee73bdeaf5
5 changed files with 6 additions and 7 deletions

View File

@ -109,10 +109,9 @@ VLC_EXPORT(int, vlc_sd_probe_Add, (vlc_probe_t *, const char *, const char *, in
#define VLC_SD_PROBE_HELPER(name, longname, cat) \
static int vlc_sd_probe_Open (vlc_object_t *obj) \
{ \
char psz_name[ strlen( name ) + strlen( longname ) + 20 ]; \
sprintf( psz_name, "%s{longname=\"%s\"}", name, longname ); \
return vlc_sd_probe_Add ((struct vlc_probe_t *)obj, \
psz_name, longname, cat); \
name "{longname=\"" longname "\"}", \
longname, cat); \
}
/** @} */

View File

@ -48,7 +48,7 @@
static int Open ( vlc_object_t * );
static void Close( vlc_object_t * );
VLC_SD_PROBE_HELPER("bonjour", N_("Bonjour services"), SD_CAT_LAN)
VLC_SD_PROBE_HELPER("bonjour", "Bonjour services", SD_CAT_LAN)
vlc_module_begin ()
set_shortname( "Bonjour" )

View File

@ -38,7 +38,7 @@
static int Open( vlc_object_t * );
static void Close( vlc_object_t * );
VLC_SD_PROBE_HELPER("mtp", N_("MTP devices"), SD_CAT_DEVICES)
VLC_SD_PROBE_HELPER("mtp", "MTP devices", SD_CAT_DEVICES)
vlc_module_begin()
set_shortname( "MTP" )

View File

@ -53,7 +53,7 @@
static int Open ( vlc_object_t * );
static void Close( vlc_object_t * );
VLC_SD_PROBE_HELPER("podcast", N_("Podcasts"), SD_CAT_INTERNET)
VLC_SD_PROBE_HELPER("podcast", "Podcasts", SD_CAT_INTERNET)
#define URLS_TEXT N_("Podcast URLs list")
#define URLS_LONGTEXT N_("Enter the list of podcasts to retrieve, " \

View File

@ -114,7 +114,7 @@
static int OpenDemux ( vlc_object_t * );
static void CloseDemux ( vlc_object_t * );
VLC_SD_PROBE_HELPER("sap", N_("Network streams (SAP)"), SD_CAT_LAN)
VLC_SD_PROBE_HELPER("sap", "Network streams (SAP)", SD_CAT_LAN)
vlc_module_begin ()
set_shortname( N_("SAP"))