[vlc-commits] OSS: remove buggy option (from 2002)

Rémi Denis-Courmont git at videolan.org
Thu Mar 31 17:19:36 CEST 2011


vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Thu Mar 31 14:23:49 2011 +0300| [96029b9eb765516741d89aa73599025f9058c3a3] | committer: Rémi Denis-Courmont

OSS: remove buggy option (from 2002)

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=96029b9eb765516741d89aa73599025f9058c3a3
---

 modules/audio_output/oss.c |   25 -------------------------
 1 files changed, 0 insertions(+), 25 deletions(-)

diff --git a/modules/audio_output/oss.c b/modules/audio_output/oss.c
index 2be5669..9c24ca1 100644
--- a/modules/audio_output/oss.c
+++ b/modules/audio_output/oss.c
@@ -71,7 +71,6 @@
 struct aout_sys_t
 {
     int i_fd;
-    int b_workaround_buggy_driver;
     int i_fragstotal;
     mtime_t max_buffer_duration;
 };
@@ -94,12 +93,6 @@ static mtime_t BufferDuration( aout_instance_t * p_aout );
 /*****************************************************************************
  * Module descriptor
  *****************************************************************************/
-#define BUGGY_TEXT N_("Try to work around buggy OSS drivers")
-#define BUGGY_LONGTEXT N_( \
-    "Some buggy OSS drivers just don't like when their internal buffers " \
-    "are completely filled (the sound gets heavily hashed). If you have one " \
-    "of these drivers, then you need to enable this option." )
-
 vlc_module_begin ()
     set_shortname( "OSS" )
     set_description( N_("UNIX OSS audio output") )
@@ -109,7 +102,6 @@ vlc_module_begin ()
     add_loadfile( "oss-audio-device", "/dev/dsp",
                   N_("OSS DSP device"), NULL, false )
         add_deprecated_alias( "dspdev" )   /* deprecated since 0.9.3 */
-    add_bool( "oss-buggy", false, BUGGY_TEXT, BUGGY_LONGTEXT, true )
 
     set_capability( "audio output", 100 )
     add_shortcut( "oss" )
@@ -509,9 +501,6 @@ static int Open( vlc_object_t *p_this )
         aout_VolumeSoftInit( p_aout );
     }
 
-    p_aout->output.p_sys->b_workaround_buggy_driver =
-        var_InheritBool( p_aout, "oss-buggy" );
-
     /* Create OSS thread and wait for its readiness. */
     if( vlc_thread_create( p_aout, OSSThread,
                            VLC_THREAD_PRIORITY_OUTPUT ) )
@@ -599,20 +588,6 @@ static void* OSSThread( vlc_object_t *p_this )
         {
             mtime_t buffered = BufferDuration( p_aout );
 
-            if( p_aout->output.p_sys->b_workaround_buggy_driver )
-            {
-#define i_fragstotal p_aout->output.p_sys->i_fragstotal
-                /* Wait a bit - we don't want our buffer to be full */
-                if( buffered > (p_aout->output.p_sys->max_buffer_duration
-                                / i_fragstotal * (i_fragstotal - 1)) )
-                {
-                    msleep((p_aout->output.p_sys->max_buffer_duration
-                                / i_fragstotal ));
-                    buffered = BufferDuration( p_aout );
-                }
-#undef i_fragstotal
-            }
-
             /* Next buffer will be played at mdate() + buffered */
             p_buffer = aout_OutputNextBuffer( p_aout, mdate() + buffered,
                                               false );



More information about the vlc-commits mailing list