Changeset 1403a857a80372af56bd37b70f24275b95f88408

Show
Ignore:
Timestamp:
06/06/08 13:10:36 (6 months ago)
Author:
Pierre d'Herbemont <pdherbemont@videolan.org>
git-committer:
Pierre d'Herbemont <pdherbemont@videolan.org> 1212750636 +0200
git-parent:

[e0791ca6584cc946e3cbd94695c88cb6bde4d289]

git-author:
Pierre d'Herbemont <pdherbemont@videolan.org> 1212750636 +0200
Message:

stream: Don't attempt to seek() when reading to NULL in *Immediate method, as pointed by Rémi.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • src/input/stream.c

    re0791ca r1403a85  
    15241524             p_read, i_read ); 
    15251525#endif 
    1526  
    1527     /* No buffer, do as if we were seeking. */ 
    1528     if( !p_read ) 
    1529     { 
    1530         /* seek within this stream if possible, else use plain old read and discard */ 
    1531         access_t     *p_access = p_sys->p_access; 
    1532  
    1533         /* seeking after EOF is not what we want */ 
    1534         if( !( p_access->info.b_eof ) ) 
    1535         { 
    1536             bool   b_aseek; 
    1537             access_Control( p_access, ACCESS_CAN_SEEK, &b_aseek ); 
    1538             if( b_aseek ) 
    1539                 return AStreamSeekImmediate( s, p_sys->i_pos + i_read ) ? 0 : i_read; 
    1540         } 
    1541     } 
    15421526 
    15431527    /* First, check if we already have some data in the buffer,