changeset 29883:306e614b92cb

Use fill_buffer if available also for STREAMTYPE_STREAM
author reimar
date Tue, 17 Nov 2009 18:05:54 +0000
parents 0ddcd4fd2ecf
children 9112683a9a02
files stream/stream.c
diffstat 1 files changed, 3 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/stream/stream.c	Tue Nov 17 16:13:20 2009 +0000
+++ b/stream/stream.c	Tue Nov 17 18:05:54 2009 +0000
@@ -254,6 +254,9 @@
 	    len=s->streaming_ctrl->streaming_read(s->fd,s->buffer,STREAM_BUFFER_SIZE, s->streaming_ctrl);
     } else
 #endif
+    if (s->fill_buffer)
+      len = s->fill_buffer(s, s->buffer, STREAM_BUFFER_SIZE);
+    else
       len=read(s->fd,s->buffer,STREAM_BUFFER_SIZE);
     break;
   case STREAMTYPE_DS: