[vlc-commits] input/stream: make stream_ReadLine work with block-based streams
Filip Roséen
git at videolan.org
Mon Jul 25 22:09:04 CEST 2016
vlc | branch: master | Filip Roséen <filip at atch.se> | Fri Jul 22 03:00:53 2016 +0200| [0b89e0efaa8087b589cbb32130f69a0fe9bbb031] | committer: Rémi Denis-Courmont
input/stream: make stream_ReadLine work with block-based streams
The if-statement in question prevents stream_ReadLine to work if invoked
with a block-based stream, as such the condition has now been altered to
only return immediately if the source stream does not have neither of
pf_read and pf_block.
--
An alternative patch would be to remove the check all-together.
- What do you guys think?
Signed-off-by: Rémi Denis-Courmont <remi at remlab.net>
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=0b89e0efaa8087b589cbb32130f69a0fe9bbb031
---
src/input/stream.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/input/stream.c b/src/input/stream.c
index d12f8d9..6c614f8 100644
--- a/src/input/stream.c
+++ b/src/input/stream.c
@@ -147,7 +147,7 @@ char *vlc_stream_ReadLine( stream_t *s )
int i_line = 0, i_read = 0;
/* Let's fail quickly if this is a readdir access */
- if( s->pf_read == NULL )
+ if( s->pf_read == NULL && s->pf_block == NULL )
return NULL;
for( ;; )
More information about the vlc-commits
mailing list