>From 2c754bf57a3e3079b127bedd6875a5e26841eac7 Mon Sep 17 00:00:00 2001
From: Antoine Cellerier <dionoea@videolan.org>
Date: Mon, 22 Sep 2008 22:28:40 +0200
Subject: [PATCH] Tag some demux options as safe.

---
 modules/demux/avi/avi.c           |    2 ++
 modules/demux/mjpeg.c             |    1 +
 modules/demux/mod.c               |   10 ++++++++++
 modules/demux/mpeg/h264.c         |    1 +
 modules/demux/mpeg/m4v.c          |    1 +
 modules/demux/playlist/playlist.c |    3 +++
 modules/demux/ps.c                |    1 +
 modules/demux/rawdv.c             |    1 +
 modules/demux/rawvid.c            |    5 +++++
 modules/demux/rtp.c               |    7 +++++++
 modules/demux/subtitle.c          |    3 +++
 modules/demux/subtitle_asa.c      |    3 +++
 modules/demux/ts.c                |    6 ++++++
 modules/demux/vc1.c               |    1 +
 14 files changed, 45 insertions(+), 0 deletions(-)

diff --git a/modules/demux/avi/avi.c b/modules/demux/avi/avi.c
index bc84ec8..d41b1b1 100644
--- a/modules/demux/avi/avi.c
+++ b/modules/demux/avi/avi.c
@@ -69,9 +69,11 @@ vlc_module_begin();
 
     add_bool( "avi-interleaved", 0, NULL,
               INTERLEAVE_TEXT, INTERLEAVE_LONGTEXT, true );
+        change_safe();
     add_integer( "avi-index", 0, NULL,
               INDEX_TEXT, INDEX_LONGTEXT, false );
         change_integer_list( pi_index, ppsz_indexes, NULL );
+        change_safe();
 
     set_callbacks( Open, Close );
 vlc_module_end();
diff --git a/modules/demux/mjpeg.c b/modules/demux/mjpeg.c
index 5415864..62b1b6f 100644
--- a/modules/demux/mjpeg.c
+++ b/modules/demux/mjpeg.c
@@ -57,6 +57,7 @@ vlc_module_begin();
     set_category( CAT_INPUT );
     set_subcategory( SUBCAT_INPUT_DEMUX );
     add_float( "mjpeg-fps", 0.0, NULL, FPS_TEXT, FPS_LONGTEXT, false );
+        change_safe();
 vlc_module_end();
 
 /*****************************************************************************
diff --git a/modules/demux/mod.c b/modules/demux/mod.c
index 399bc00..a845f56 100644
--- a/modules/demux/mod.c
+++ b/modules/demux/mod.c
@@ -74,27 +74,37 @@ vlc_module_begin();
 
     add_bool( "mod-noisereduction", true, NULL, N_("Noise reduction"),
               NOISE_LONGTEXT, false );
+        change_safe();
 
     add_bool( "mod-reverb", false, NULL, N_("Reverb"),
               REVERB_LONGTEXT, false );
+        change_safe();
     add_integer_with_range( "mod-reverb-level", 0, 0, 100, NULL,
              N_("Reverberation level"), REVERB_LEVEL_LONGTEXT, true );
+        change_safe();
     add_integer_with_range( "mod-reverb-delay", 40, 0, 1000, NULL,
              N_("Reverberation delay"), REVERB_DELAY_LONGTEXT, true );
+        change_safe();
 
     add_bool( "mod-megabass", false, NULL, N_("Mega bass"),
                     MEGABASS_LONGTEXT, false );
+        change_safe();
     add_integer_with_range( "mod-megabass-level", 0, 0, 100, NULL,
               N_("Mega bass level"), MEGABASS_LEVEL_LONGTEXT, true );
+        change_safe();
     add_integer_with_range( "mod-megabass-range", 10, 10, 100, NULL,
               N_("Mega bass cutoff"), MEGABASS_RANGE_LONGTEXT, true );
+        change_safe();
 
     add_bool( "mod-surround", false, NULL, N_("Surround"), N_("Surround"),
                false );
+        change_safe();
     add_integer_with_range( "mod-surround-level", 0, 0, 100, NULL,
               N_("Surround level"), SURROUND_LEVEL_LONGTEXT, true );
+        change_safe();
     add_integer_with_range( "mod-surround-delay", 5, 0, 1000, NULL,
               N_("Surround delay (ms)"), SURROUND_DELAY_LONGTEXT, true );
+        change_safe();
 
     set_callbacks( Open, Close );
     add_shortcut( "mod" );
diff --git a/modules/demux/mpeg/h264.c b/modules/demux/mpeg/h264.c
index a529cab..246b931 100644
--- a/modules/demux/mpeg/h264.c
+++ b/modules/demux/mpeg/h264.c
@@ -51,6 +51,7 @@ vlc_module_begin();
     set_description( N_("H264 video demuxer" ) );
     set_capability( "demux", 0 );
     add_float( "h264-fps", 25.0, NULL, FPS_TEXT, FPS_LONGTEXT, true );
+        change_safe();
     set_callbacks( Open, Close );
     add_shortcut( "h264" );
 vlc_module_end();
diff --git a/modules/demux/mpeg/m4v.c b/modules/demux/mpeg/m4v.c
index d51ab69..bd1adfd 100644
--- a/modules/demux/mpeg/m4v.c
+++ b/modules/demux/mpeg/m4v.c
@@ -53,6 +53,7 @@ vlc_module_begin();
     add_shortcut( "m4v" );
     add_shortcut( "mp4v" );
     add_float( "m4v-fps", 25, NULL, FPS_TEXT, FPS_LONGTEXT, false );
+        change_safe();
 vlc_module_end();
 
 /*****************************************************************************
diff --git a/modules/demux/playlist/playlist.c b/modules/demux/playlist/playlist.c
index 3b8374d..a0c2e10 100644
--- a/modules/demux/playlist/playlist.c
+++ b/modules/demux/playlist/playlist.c
@@ -56,12 +56,14 @@ vlc_module_begin();
 
     add_bool( "playlist-autostart", 1, NULL,
               AUTOSTART_TEXT, AUTOSTART_LONGTEXT, false );
+        change_safe();
 
     add_integer( "parent-item", 0, NULL, NULL, NULL, true );
         change_internal();
 
     add_bool( "playlist-skip-ads", 1, NULL,
               SKIP_ADS_TEXT, SKIP_ADS_LONGTEXT, false );
+        change_safe();
 
     set_shortname( N_("Playlist") );
     set_description( N_("Playlist") );
@@ -103,6 +105,7 @@ vlc_module_begin();
         set_callbacks( Import_Shoutcast, Close_Shoutcast );
         add_bool( "shoutcast-show-adult", false, NULL,
                    SHOW_ADULT_TEXT, SHOW_ADULT_LONGTEXT, false );
+            change_safe();
     add_submodule();
         set_description( N_("ASX playlist import") );
         add_shortcut( "asx-open" );
diff --git a/modules/demux/ps.c b/modules/demux/ps.c
index 1a6adab..17cdec2 100644
--- a/modules/demux/ps.c
+++ b/modules/demux/ps.c
@@ -62,6 +62,7 @@ vlc_module_begin();
 
     add_bool( "ps-trust-timestamps", true, NULL, TIME_TEXT,
                  TIME_LONGTEXT, true );
+        change_safe();
 
     add_submodule();
     set_description( N_("MPEG-PS demuxer") );
diff --git a/modules/demux/rawdv.c b/modules/demux/rawdv.c
index 627220a..ce93d3a 100644
--- a/modules/demux/rawdv.c
+++ b/modules/demux/rawdv.c
@@ -51,6 +51,7 @@ vlc_module_begin();
     set_category( CAT_INPUT );
     set_subcategory( SUBCAT_INPUT_DEMUX );
     add_bool( "rawdv-hurry-up", 0, NULL, HURRYUP_TEXT, HURRYUP_LONGTEXT, false );
+        change_safe();
     set_callbacks( Open, Close );
     add_shortcut( "rawdv" );
 vlc_module_end();
diff --git a/modules/demux/rawvid.c b/modules/demux/rawvid.c
index 542f20a..400123c 100644
--- a/modules/demux/rawvid.c
+++ b/modules/demux/rawvid.c
@@ -69,12 +69,17 @@ vlc_module_begin();
     set_callbacks( Open, Close );
     add_shortcut( "rawvideo" );
     add_float( "rawvid-fps", 0, 0, FPS_TEXT, FPS_LONGTEXT, false );
+        change_safe();
     add_integer( "rawvid-width", 0, 0, WIDTH_TEXT, WIDTH_LONGTEXT, 0 );
+        change_safe();
     add_integer( "rawvid-height", 0, 0, HEIGHT_TEXT, HEIGHT_LONGTEXT, 0 );
+        change_safe();
     add_string( "rawvid-chroma", NULL, NULL, CHROMA_TEXT, CHROMA_LONGTEXT,
                 true );
+        change_safe();
     add_string( "rawvid-aspect-ratio", NULL, NULL,
                 ASPECT_RATIO_TEXT, ASPECT_RATIO_LONGTEXT, true );
+        change_safe();
 vlc_module_end();
 
 /*****************************************************************************
diff --git a/modules/demux/rtp.c b/modules/demux/rtp.c
index 1d819b4..c9b8e41 100644
--- a/modules/demux/rtp.c
+++ b/modules/demux/rtp.c
@@ -89,21 +89,28 @@ vlc_module_begin ();
     add_integer ("rtp-caching", 1000, NULL, RTP_CACHING_TEXT,
                  RTP_CACHING_LONGTEXT, true);
         change_integer_range (0, 65535);
+        change_safe();
     add_string ("srtp-key", "", NULL,
                 SRTP_KEY_TEXT, SRTP_KEY_LONGTEXT, false);
+        change_safe();
     add_string ("srtp-salt", "", NULL,
                 SRTP_SALT_TEXT, SRTP_SALT_LONGTEXT, false);
+        change_safe();
     add_integer ("rtp-max-src", 1, NULL, RTP_MAX_SRC_TEXT,
                  RTP_MAX_SRC_LONGTEXT, true);
         change_integer_range (1, 255);
+        change_safe();
     add_integer ("rtp-timeout", 5, NULL, RTP_TIMEOUT_TEXT,
                  RTP_TIMEOUT_LONGTEXT, true);
+        change_safe();
     add_integer ("rtp-max-dropout", 3000, NULL, RTP_MAX_DROPOUT_TEXT,
                  RTP_MAX_DROPOUT_LONGTEXT, true);
         change_integer_range (0, 32767);
+        change_safe();
     add_integer ("rtp-max-misorder", 100, NULL, RTP_MAX_MISORDER_TEXT,
                  RTP_MAX_MISORDER_LONGTEXT, true);
         change_integer_range (0, 32767);
+        change_safe();
 
     add_shortcut ("dccp");
     /*add_shortcut ("sctp");*/
diff --git a/modules/demux/subtitle.c b/modules/demux/subtitle.c
index 16ca09c..c219642 100644
--- a/modules/demux/subtitle.c
+++ b/modules/demux/subtitle.c
@@ -79,12 +79,15 @@ vlc_module_begin();
     add_float( "sub-fps", 0.0, NULL,
                N_("Frames per second"),
                SUB_FPS_LONGTEXT, true );
+        change_safe();
     add_integer( "sub-delay", 0, NULL,
                N_("Subtitles delay"),
                SUB_DELAY_LONGTEXT, true );
+        change_safe();
     add_string( "sub-type", "auto", NULL, N_("Subtitles format"),
                 SUB_TYPE_LONGTEXT, true );
         change_string_list( ppsz_sub_type, NULL, NULL );
+        change_safe();
     set_callbacks( Open, Close );
 
     add_shortcut( "subtitle" );
diff --git a/modules/demux/subtitle_asa.c b/modules/demux/subtitle_asa.c
index 53899e1..dd17cc1 100644
--- a/modules/demux/subtitle_asa.c
+++ b/modules/demux/subtitle_asa.c
@@ -69,11 +69,14 @@ vlc_module_begin();
     add_float( "sub-fps", 0.0, NULL,
                N_("Frames per second"),
                SUB_FPS_LONGTEXT, true );
+        change_safe();
     add_integer( "sub-delay", 0, NULL,
                N_("Subtitles delay"),
                SUB_DELAY_LONGTEXT, true );
+        change_safe();
     add_string( "sub-type", "auto", NULL, N_("Subtitles format"),
                 SUB_TYPE_LONGTEXT, true );
+        change_safe();
     set_callbacks( Open, Close );
 
     add_shortcut( "asademux" );
diff --git a/modules/demux/ts.c b/modules/demux/ts.c
index 3549913..86cc504 100644
--- a/modules/demux/ts.c
+++ b/modules/demux/ts.c
@@ -162,14 +162,20 @@ vlc_module_begin();
     set_subcategory( SUBCAT_INPUT_DEMUX );
 
     add_string( "ts-extra-pmt", NULL, NULL, PMT_TEXT, PMT_LONGTEXT, true );
+        change_safe();
     add_bool( "ts-es-id-pid", 1, NULL, PID_TEXT, PID_LONGTEXT, true );
+        change_safe();
     add_string( "ts-out", NULL, NULL, TSOUT_TEXT, TSOUT_LONGTEXT, true );
     add_integer( "ts-out-mtu", 1400, NULL, MTUOUT_TEXT,
                  MTUOUT_LONGTEXT, true );
     add_string( "ts-csa-ck", NULL, NULL, CSA_TEXT, CSA_LONGTEXT, true );
+        change_safe();
     add_string( "ts-csa2-ck", NULL, NULL, CSA_TEXT, CSA_LONGTEXT, true );
+        change_safe();
     add_integer( "ts-csa-pkt", 188, NULL, CPKT_TEXT, CPKT_LONGTEXT, true );
+        change_safe();
     add_bool( "ts-silent", 0, NULL, SILENT_TEXT, SILENT_LONGTEXT, true );
+        change_safe();
 
     add_file( "ts-dump-file", NULL, NULL, TSDUMP_TEXT, TSDUMP_LONGTEXT, false );
     add_bool( "ts-dump-append", 0, NULL, APPEND_TEXT, APPEND_LONGTEXT, false );
diff --git a/modules/demux/vc1.c b/modules/demux/vc1.c
index 31f78c1..5c3a6e3 100644
--- a/modules/demux/vc1.c
+++ b/modules/demux/vc1.c
@@ -50,6 +50,7 @@ vlc_module_begin();
     set_description( N_("VC1 video demuxer" ) );
     set_capability( "demux", 0 );
     add_float( "vc1-fps", 25.0, NULL, FPS_TEXT, FPS_LONGTEXT, true );
+        change_safe();
     set_callbacks( Open, Close );
     add_shortcut( "vc1" );
 vlc_module_end();
-- 
1.5.6.5

