summaryrefslogtreecommitdiffstats
path: root/command.c
diff options
context:
space:
mode:
authorfaust3 <faust3@b3059339-0415-0410-9bf9-f77b7e298cf2>2008-10-27 22:44:09 +0000
committerfaust3 <faust3@b3059339-0415-0410-9bf9-f77b7e298cf2>2008-10-27 22:44:09 +0000
commit472bf28b5ec3208ee0ba5fc3801dc49f631c8588 (patch)
tree7dbba63be81d63de4c0a92037c35feb5a9c3f6b9 /command.c
parent65db2ef94474b19b5c17308ae6fd624bad86ff1d (diff)
downloadmpv-472bf28b5ec3208ee0ba5fc3801dc49f631c8588.tar.bz2
mpv-472bf28b5ec3208ee0ba5fc3801dc49f631c8588.tar.xz
Disallow the modification of teletext properties when the tv demuxer is
not active. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27840 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'command.c')
-rw-r--r--command.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/command.c b/command.c
index 0ed2b759bb..25b9231b1b 100644
--- a/command.c
+++ b/command.c
@@ -1949,6 +1949,8 @@ static int mp_property_teletext_page(m_option_t * prop, int action, void *arg,
tvi_handle_t *tvh = mpctx->demuxer->priv;
int result;
int val;
+ if (mpctx->demuxer->type != DEMUXER_TYPE_TV || !tvh)
+ return M_PROPERTY_UNAVAILABLE;
switch(action){
case M_PROPERTY_STEP_UP:
case M_PROPERTY_STEP_DOWN: