]> git.sesse.net Git - vlc/commitdiff
* all: access plugins should not modify
authorLaurent Aimar <fenrir@videolan.org>
Wed, 11 Dec 2002 20:13:50 +0000 (20:13 +0000)
committerLaurent Aimar <fenrir@videolan.org>
Wed, 11 Dec 2002 20:13:50 +0000 (20:13 +0000)
p_input->stream.p_selected_area->i_tell when reading data. (It's done in
input_SplitBuffer). (But access should still set it on a "seek")

modules/access/http.c
modules/access/rtp.c
modules/access/udp.c

index fcd91236d8d05734a954c06d03cf73a1a4bad15c..f494ac82c7f508005a8dab1444e68178b4968dfc 100644 (file)
@@ -2,7 +2,7 @@
  * http.c: HTTP access plug-in
  *****************************************************************************
  * Copyright (C) 2001, 2002 VideoLAN
- * $Id: http.c,v 1.15 2002/12/06 12:54:30 sam Exp $
+ * $Id: http.c,v 1.16 2002/12/11 20:13:50 fenrir Exp $
  *
  * Authors: Christophe Massiot <massiot@via.ecp.fr>
  *
@@ -362,7 +362,7 @@ static int HTTPConnect( input_thread_t * p_input, off_t i_tell )
 
     if( p_input->stream.p_selected_area->i_size )
     {
-        p_input->stream.p_selected_area->i_tell = i_tell
+        p_input->stream.p_selected_area->i_tell = i_tell;
             + (p_input->p_last_data - p_input->p_current_data);
     }
     else
@@ -708,13 +708,6 @@ static ssize_t Read( input_thread_t * p_input, byte_t * p_buffer, size_t i_len )
     {
         ssize_t i_recv = recv( p_access_data->i_handle, p_buffer, i_len, 0 );
 
-        if( i_recv > 0 )
-        {
-            vlc_mutex_lock( &p_input->stream.stream_lock );
-            p_input->stream.p_selected_area->i_tell += i_recv;
-            vlc_mutex_unlock( &p_input->stream.stream_lock );
-        }
-
         if( i_recv < 0 )
         {
 #ifdef HAVE_ERRNO_H
index 3462cc7edcf9e65db03c9035d2218affbae4018f..73556af2a122d6cb93a3084b8861e7f4e3ab4fb0 100644 (file)
@@ -2,7 +2,7 @@
  * rtp.c: RTP access plug-in
  *****************************************************************************
  * Copyright (C) 2001, 2002 VideoLAN
- * $Id: rtp.c,v 1.7 2002/12/06 16:34:04 sam Exp $
+ * $Id: rtp.c,v 1.8 2002/12/11 20:13:50 fenrir Exp $
  *
  * Authors: Tristan Leteurtre <tooney@via.ecp.fr>
  *
@@ -380,13 +380,6 @@ static ssize_t Read( input_thread_t * p_input, byte_t * p_buffer, size_t i_len )
     {
         ssize_t i_recv = recv( p_access_data->i_handle, p_buffer, i_len, 0 );
 
-        if( i_recv > 0 )
-        {
-            vlc_mutex_lock( &p_input->stream.stream_lock );
-            p_input->stream.p_selected_area->i_tell += i_recv;
-            vlc_mutex_unlock( &p_input->stream.stream_lock );
-        }
-
         if( i_recv < 0 )
         {
             msg_Err( p_input, "recv failed (%s)", strerror(errno) );
index 2138287d56ef33fcf7eeb438f736c02d8ccef28b..a086d846f62148c0c43060aedaaacd8cbd5f8334 100644 (file)
@@ -2,7 +2,7 @@
  * udp.c: raw UDP access plug-in
  *****************************************************************************
  * Copyright (C) 2001, 2002 VideoLAN
- * $Id: udp.c,v 1.4 2002/11/12 13:57:12 sam Exp $
+ * $Id: udp.c,v 1.5 2002/12/11 20:13:50 fenrir Exp $
  *
  * Authors: Christophe Massiot <massiot@via.ecp.fr>
  *
@@ -320,13 +320,6 @@ static ssize_t Read( input_thread_t * p_input, byte_t * p_buffer, size_t i_len )
     {
         ssize_t i_recv = recv( p_access_data->i_handle, p_buffer, i_len, 0 );
 
-        if( i_recv > 0 )
-        {
-            vlc_mutex_lock( &p_input->stream.stream_lock );
-            p_input->stream.p_selected_area->i_tell += i_recv;
-            vlc_mutex_unlock( &p_input->stream.stream_lock );
-        }
-
         if( i_recv < 0 )
         {
             msg_Err( p_input, "recv failed (%s)", strerror(errno) );