X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=modules%2Fmisc%2Faudioscrobbler.c;h=d28b6beec211314bcdecc3dde0a21d6ab3f30789;hb=ea96e3832d87f251cadafdc6e62aec71792a39f2;hp=e08e79028027d5076537d0cdd31334644d845230;hpb=1c54a6ae9a4068ff4790459a31d22dd066567c24;p=vlc diff --git a/modules/misc/audioscrobbler.c b/modules/misc/audioscrobbler.c index e08e790280..d28b6beec2 100644 --- a/modules/misc/audioscrobbler.c +++ b/modules/misc/audioscrobbler.c @@ -30,8 +30,6 @@ * Preamble *****************************************************************************/ -#define _GNU_SOURCE -#include #if defined( WIN32 ) #include @@ -151,7 +149,7 @@ vlc_module_begin(); set_description( N_("Audioscrobbler submission Plugin") ); add_string( "lastfm-username", "", NULL, USERNAME_TEXT, USERNAME_LONGTEXT, VLC_FALSE ); - add_string( "lastfm-password", "", NULL, + add_password( "lastfm-password", "", NULL, PASSWORD_TEXT, PASSWORD_LONGTEXT, VLC_FALSE ); set_capability( "interface", 0 ); set_callbacks( Open, Close ); @@ -367,6 +365,10 @@ static void Run( intf_thread_t *p_this ) vlc_mutex_unlock ( &p_sys->lock ); break; } + /* handshake is done or failed, lets start from + * beginning to check it out and wait INTERVAL if needed + */ + continue; } msg_Dbg( p_this, "Going to submit some data..." ); @@ -1095,7 +1097,7 @@ static int ReadMetaData( intf_thread_t *p_this ) else psz_trackid = calloc( 1, 1 ); - i_length = input_GetItem(p_input)->i_duration / 1000000; + i_length = input_item_GetDuration( input_GetItem( p_input ) ) / 1000000; vlc_mutex_lock ( &p_sys->lock );