[vlc-commits] demux: adaptive: output error on invalid logic
Francois Cartegnie
git at videolan.org
Mon Mar 30 16:15:26 CEST 2020
vlc/vlc-3.0 | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Fri May 10 18:39:29 2019 +0200| [0d64afca486a0c2b2f93eb54628baf8623dccd7f] | committer: Francois Cartegnie
demux: adaptive: output error on invalid logic
(cherry picked from commit 38fc93897621cd42ee2c80d879db7c4580a06629)
> http://git.videolan.org/gitweb.cgi/vlc/vlc-3.0.git/?a=commit;h=0d64afca486a0c2b2f93eb54628baf8623dccd7f
---
modules/demux/adaptive/adaptive.cpp | 3 +++
1 file changed, 3 insertions(+)
diff --git a/modules/demux/adaptive/adaptive.cpp b/modules/demux/adaptive/adaptive.cpp
index 2ffb8f6314..714f91c1e0 100644
--- a/modules/demux/adaptive/adaptive.cpp
+++ b/modules/demux/adaptive/adaptive.cpp
@@ -160,6 +160,7 @@ static int Open(vlc_object_t *p_obj)
AbstractAdaptationLogic::LogicType logic = AbstractAdaptationLogic::Default;
if( psz_logic )
{
+ bool b_found = false;
for(size_t i=0;i<ARRAY_SIZE(pi_logics); i++)
{
if(!strcmp(psz_logic, ppsz_logics_values[i]))
@@ -169,6 +170,8 @@ static int Open(vlc_object_t *p_obj)
break;
}
}
+ if(!b_found)
+ msg_Err(p_demux, "Unknown adaptive-logic value '%s'", psz_logic);
free( psz_logic );
}
More information about the vlc-commits
mailing list