Commit 9a618af2 authored by Jean-Paul Saman's avatar Jean-Paul Saman

dbus: return the exact number of elementary streams from the source.

parent c38c5d07
......@@ -801,7 +801,7 @@ DBUS_METHOD( CountVideoES )
{
vlc_value_t val_list;
var_Change( p_input, "video-es", VLC_VAR_GETCHOICES, &val_list, NULL );
i_count = val_list.p_list->i_count;
i_count = (val_list.p_list->i_count > 0) ? (val_list.p_list->i_count - 1): 0;
vlc_object_release( p_input );
}
pl_Release( (vlc_object_t*) p_this );
......@@ -910,7 +910,7 @@ DBUS_METHOD( CountAudioES )
{
vlc_value_t val_list;
var_Change( p_input, "audio-es", VLC_VAR_GETCHOICES, &val_list, NULL );
i_count = val_list.p_list->i_count;
i_count = (val_list.p_list->i_count > 0) ? (val_list.p_list->i_count - 1): 0;
vlc_object_release( p_input );
}
pl_Release( (vlc_object_t*) p_this );
......@@ -1023,7 +1023,7 @@ DBUS_METHOD( CountSubtitleES )
{
vlc_value_t val_list;
var_Change( p_input, "spu-es", VLC_VAR_GETCHOICES, &val_list, NULL );
i_count = val_list.p_list->i_count;
i_count = (val_list.p_list->i_count > 0) ? (val_list.p_list->i_count - 1): 0;
vlc_object_release( p_input );
}
pl_Release( (vlc_object_t*) p_this );
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment