Browse Source

modules: use VLC_HARD_MIN_SLEEP instead of hardcoded values

pull/70/head
Steve Lhomme 8 years ago
parent
commit
4f672c3f1e
  1. 2
      modules/access/avcapture.m
  2. 2
      modules/access/dc1394.c
  3. 4
      modules/access/idummy.c
  4. 2
      modules/access/qtsound.m
  5. 6
      modules/demux/avi/avi.c
  6. 2
      modules/demux/ogg.c

2
modules/access/avcapture.m

@ -408,7 +408,7 @@ static int Demux(demux_t *p_demux)
{
/* Nothing to display yet, just forget */
block_Release(p_block);
msleep(10000);
msleep(VLC_HARD_MIN_SLEEP);
return 1;
}
else if ( !p_sys->b_es_setup )

2
modules/access/dc1394.c

@ -470,7 +470,7 @@ static int Demux( demux_t *p_demux )
/* Sleep so we do not consume all the cpu, 10ms seems
* like a good value (100fps)
*/
msleep( 10000 );
msleep( VLC_HARD_MIN_SLEEP );
return 1;
}

4
modules/access/idummy.c

@ -56,7 +56,7 @@ static int DemuxNoOp( demux_t *demux )
static int DemuxHold( demux_t *demux )
{
(void) demux;
msleep( 10000 ); /* FIXME!!! */
msleep( VLC_HARD_MIN_SLEEP ); /* FIXME!!! */
return 1;
}
@ -74,7 +74,7 @@ static int DemuxPause( demux_t *demux )
if( now >= p_sys->end )
return 0;
msleep( 10000 ); /* FIXME!!! */
msleep( VLC_HARD_MIN_SLEEP ); /* FIXME!!! */
return 1;
}

2
modules/access/qtsound.m

@ -516,7 +516,7 @@ static int Demux(demux_t *p_demux)
block_Release(p_blocka);
// Nothing to transfer yet, just forget
msleep(10000);
msleep(VLC_HARD_MIN_SLEEP);
return 1;
}

6
modules/demux/avi/avi.c

@ -1186,7 +1186,7 @@ static int Demux_Seekable( demux_t *p_demux )
* affect the reading speed too much. */
if( !(++i_loop_count % 1024) )
{
msleep( 10000 );
msleep( VLC_HARD_MIN_SLEEP );
if( !(i_loop_count % (1024 * 10)) )
msg_Warn( p_demux,
@ -1919,7 +1919,7 @@ static int AVI_StreamChunkFind( demux_t *p_demux, unsigned int i_stream )
* affect the reading speed too much. */
if( !(++i_loop_count % 1024) )
{
msleep( 10000 );
msleep( VLC_HARD_MIN_SLEEP );
if( !(i_loop_count % (1024 * 10)) )
msg_Warn( p_demux, "don't seem to find any data..." );
@ -2338,7 +2338,7 @@ static int AVI_PacketSearch( demux_t *p_demux )
* this code is called only on broken files). */
if( !(++i_count % 1024) )
{
msleep( 10000 );
msleep( VLC_HARD_MIN_SLEEP );
if( !(i_count % (1024 * 10)) )
msg_Warn( p_demux, "trying to resync..." );
}

2
modules/demux/ogg.c

@ -1481,7 +1481,7 @@ static void Ogg_DecodePacket( demux_t *p_demux,
/* FIXME: the biggest hack I've ever done */
msg_Warn( p_demux, "tarkin pts: %"PRId64", granule: %"PRId64,
p_block->i_pts, p_block->i_dts );
msleep(10000);
msleep(VLC_HARD_MIN_SLEEP);
}
/* Blatant abuse of the i_length field. */

Loading…
Cancel
Save