]> git.sesse.net Git - vlc/commitdiff
* FINALLY fixed HTTP input bug (I'm SO HAPPY with this !)
authorChristophe Massiot <massiot@videolan.org>
Thu, 4 Apr 2002 22:51:01 +0000 (22:51 +0000)
committerChristophe Massiot <massiot@videolan.org>
Thu, 4 Apr 2002 22:51:01 +0000 (22:51 +0000)
* Disabled memcpyaltivec since it's buggy

configure
configure.in
plugins/mpeg_system/mpeg_ps.c
src/input/input.c
src/input/mpeg_system.c

index 1512e971db1d4648d958c772455380ce02d97d85..72d1a1e11ea3b8b0243efedeaa124c357daff330 100755 (executable)
--- a/configure
+++ b/configure
@@ -5291,7 +5291,7 @@ THREEDNOW_MODULES="memcpy3dn imdct3dn downmix3dn"
 if test x$SYS != xmingw32; then
   SSE_MODULES="imdctsse downmixsse"
 fi
-ALTIVEC_MODULES="idctaltivec motionaltivec memcpyaltivec"
+ALTIVEC_MODULES="idctaltivec motionaltivec"
 
 echo $ac_n "checking if \$CC groks MMX inline assembly""... $ac_c" 1>&6
 echo "configure:5298: checking if \$CC groks MMX inline assembly" >&5
index baceae25fe13d17aef0a0a387805b3a2f078de7d..f2c562a32fe0e4dd50cbb80de4c6b0187173dcfe 100644 (file)
@@ -380,7 +380,7 @@ THREEDNOW_MODULES="memcpy3dn imdct3dn downmix3dn"
 if test x$SYS != xmingw32; then
   SSE_MODULES="imdctsse downmixsse"
 fi
-ALTIVEC_MODULES="idctaltivec motionaltivec memcpyaltivec"
+ALTIVEC_MODULES="idctaltivec motionaltivec"
 
 AC_CACHE_CHECK([if \$CC groks MMX inline assembly],
     [ac_cv_mmx_inline],
index b9567719ae654deeebf00ceb00b27611ef0bb136..64c23d9f6dd047c35192f42878be75519bc28b38 100644 (file)
@@ -2,7 +2,7 @@
  * mpeg_ps.c : Program Stream input module for vlc
  *****************************************************************************
  * Copyright (C) 2000-2001 VideoLAN
- * $Id: mpeg_ps.c,v 1.8 2002/03/18 19:14:52 sam Exp $
+ * $Id: mpeg_ps.c,v 1.9 2002/04/04 22:51:01 massiot Exp $
  *
  * Authors: Christophe Massiot <massiot@via.ecp.fr>
  *
@@ -185,8 +185,8 @@ static int PSInit( input_thread_t * p_input )
                 break;
             }
         }
-        p_input->pf_seek( p_input, (off_t)0 );
         input_AccessReinit( p_input );
+        p_input->pf_seek( p_input, (off_t)0 );
         vlc_mutex_lock( &p_input->stream.stream_lock );
 
         if( p_demux_data->b_has_PSM )
index 09d4346c13d728912596f5049fe1b39d5a7a37f2..47875aee5c95ba403e2a87517bde880e10e8f53d 100644 (file)
@@ -4,10 +4,9 @@
  * decoders.
  *****************************************************************************
  * Copyright (C) 1998-2001 VideoLAN
- * $Id: input.c,v 1.191 2002/03/18 21:04:01 xav Exp $
+ * $Id: input.c,v 1.192 2002/04/04 22:51:01 massiot Exp $
  *
  * Authors: Christophe Massiot <massiot@via.ecp.fr>
- *          Alexis Guillard <alexis.guillard@bt.com>
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
@@ -324,6 +323,7 @@ static int RunThread( input_thread_t *p_input )
         {
             if( p_input->stream.b_seekable && p_input->pf_set_area != NULL )
             {
+                input_AccessReinit( p_input );
 
                 p_input->pf_set_area( p_input, p_input->stream.p_new_area );
 
@@ -338,8 +338,6 @@ static int RunThread( input_thread_t *p_input )
                     /* Reinitialize synchro. */
                     p_pgrm->i_synchro_state = SYNCHRO_REINIT;
                 }
-
-                input_AccessReinit( p_input );
             }
             p_input->stream.p_new_area = NULL;
         }
@@ -348,7 +346,12 @@ static int RunThread( input_thread_t *p_input )
         {
             if( p_input->stream.b_seekable && p_input->pf_seek != NULL )
             {
-                off_t i_new_pos = p_input->stream.p_selected_area->i_seek;
+                off_t i_new_pos;
+
+                /* Reinitialize buffer manager. */
+                input_AccessReinit( p_input );
+
+                i_new_pos = p_input->stream.p_selected_area->i_seek;
                 vlc_mutex_unlock( &p_input->stream.stream_lock );
                 p_input->pf_seek( p_input, i_new_pos );
                 vlc_mutex_lock( &p_input->stream.stream_lock );
@@ -364,9 +367,6 @@ static int RunThread( input_thread_t *p_input )
                     /* Reinitialize synchro. */
                     p_pgrm->i_synchro_state = SYNCHRO_REINIT;
                 }
-
-                /* Reinitialize buffer manager. */
-                input_AccessReinit( p_input );
             }
             p_input->stream.p_selected_area->i_seek = NO_SEEK;
         }
index f6b7040da3d4538c3000cab706fd7b977043cb87..f4804c462c9626e786184924a6f976a6374fe896 100644 (file)
@@ -2,7 +2,7 @@
  * mpeg_system.c: TS, PS and PES management
  *****************************************************************************
  * Copyright (C) 1998-2001 VideoLAN
- * $Id: mpeg_system.c,v 1.87 2002/03/20 17:44:15 sam Exp $
+ * $Id: mpeg_system.c,v 1.88 2002/04/04 22:51:01 massiot Exp $
  *
  * Authors: Christophe Massiot <massiot@via.ecp.fr>
  *          Michel Lespinasse <walken@via.ecp.fr>
@@ -662,20 +662,20 @@ ssize_t input_ReadPS( input_thread_t * p_input, data_packet_t ** pp_data )
     /* Read what we believe to be a packet header. */
     PEEK( 4 );
 
-    if( *p_peek || *(p_peek + 1) || *(p_peek + 2) != 1 )
+    if( p_peek[0] || p_peek[1] || p_peek[2] != 1 || p_peek[3] < 0xB9 )
     {
-        if( *p_peek || *(p_peek + 1) || *(p_peek + 2) )
+        if( p_peek[0] || p_peek[1] || p_peek[2] )
         {
             /* It is common for MPEG-1 streams to pad with zeros
              * (although it is forbidden by the recommendation), so
              * don't bother everybody in this case. */
             intf_WarnMsg( 3, "input warning: garbage (0x%.2x%.2x%.2x%.2x)",
-                 *p_peek, *(p_peek + 1), *(p_peek + 2), *(p_peek + 3) );
+                 p_peek[0], p_peek[1], p_peek[2], p_peek[3] );
         }
 
         /* This is not the startcode of a packet. Read the stream
          * until we find one. */
-        while( *p_peek || *(p_peek + 1) || *(p_peek + 2) != 1 )
+        while( p_peek[0] || p_peek[1] || p_peek[2] != 1 || p_peek[3] < 0xB9 )
         {
             p_input->p_current_data++;
             PEEK( 4 );