]> git.sesse.net Git - vlc/blobdiff - modules/control/rc.c
Use input_GetVout
[vlc] / modules / control / rc.c
index e9f90058b057fd805d4383151869414b711ce9c4..8a85af2c01ed4319e20356c8a2825bb7032607bb 100644 (file)
 #ifdef HAVE_UNISTD_H
 #    include <unistd.h>
 #endif
-
-#ifdef HAVE_SYS_TIME_H
-#    include <sys/time.h>
-#endif
 #include <sys/types.h>
 
 #include <vlc_network.h>
@@ -443,7 +439,7 @@ static void RegisterCallbacks( intf_thread_t *p_intf )
 static void Run( intf_thread_t *p_intf )
 {
     input_thread_t * p_input = NULL;
-    playlist_t *     p_playlist = pl_Hold( p_intf );
+    playlist_t *     p_playlist = pl_Get( p_intf );
 
     char p_buffer[ MAX_LINE_LENGTH + 1 ];
     bool b_showpos = var_InheritInteger( p_intf, "rc-show-pos" );
@@ -747,9 +743,7 @@ static void Run( intf_thread_t *p_intf )
         case 'F':
             if( p_input )
             {
-                vout_thread_t *p_vout;
-                p_vout = input_GetVout( p_input );
-
+                vout_thread_t *p_vout = input_GetVout( p_input );
                 if( p_vout )
                 {
                     vlc_value_t val;
@@ -804,8 +798,6 @@ static void Run( intf_thread_t *p_intf )
         vlc_object_release( p_input );
     }
 
-    pl_Release( p_intf );
-
     var_DelCallback( p_intf->p_libvlc, "volume-change", VolumeChanged, p_intf );
     vlc_restorecancel( canc );
 }