play command fix by ILEoo (see [18938]).
authorAntoine Cellerier <dionoea@videolan.org>
Thu, 22 Feb 2007 19:02:19 +0000 (19:02 +0000)
committerAntoine Cellerier <dionoea@videolan.org>
Thu, 22 Feb 2007 19:02:19 +0000 (19:02 +0000)
src/input/vlm.c

index d729ac6..17c3870 100644 (file)
@@ -2500,7 +2500,7 @@ static int Manage( vlc_object_t* p_object )
                 {
                     /* FIXME, find a way to select the right instance */
                     char buffer[12];
                 {
                     /* FIXME, find a way to select the right instance */
                     char buffer[12];
-                    sprintf( buffer, "%d", p_instance->i_index );
+                    sprintf( buffer, "%d", p_instance->i_index+1 );
                     vlm_MediaControl( vlm, p_media, p_instance->psz_name,
                                       "play", buffer );
                 }
                     vlm_MediaControl( vlm, p_media, p_instance->psz_name,
                                       "play", buffer );
                 }
@@ -2509,8 +2509,8 @@ static int Manage( vlc_object_t* p_object )
                     if( vlm_MediaControl( vlm, p_media, p_instance->psz_name,
                                           "stop", 0 ) == VLC_SUCCESS )
                     {
                     if( vlm_MediaControl( vlm, p_media, p_instance->psz_name,
                                           "stop", 0 ) == VLC_SUCCESS )
                     {
-                        j--; /* the aray is one element smaller now. */
-                   }
+                         j--; /* the aray is one element smaller now. */
+                    }
                 }
             }
         }
                 }
             }
         }