From aa87c143cb369f1448f8d08086b5ef98998b4436 Mon Sep 17 00:00:00 2001 From: wm4 Date: Sat, 24 May 2014 14:06:13 +0200 Subject: stream: remove chaos related to writeable streams For some reason, we support writeable streams. (Only encoding uses that, and the use of it looks messy enough that I want to replace it with FILE or avio today.) It's a chaos: most streams do not actually check the mode parameter like they should. Simplify it, and let streams signal availability of write mode by setting a flag in the stream info struct. --- stream/stream_memory.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'stream/stream_memory.c') diff --git a/stream/stream_memory.c b/stream/stream_memory.c index df01d2956e..b748c9264c 100644 --- a/stream/stream_memory.c +++ b/stream/stream_memory.c @@ -55,7 +55,7 @@ static int control(stream_t *s, int cmd, void *arg) return STREAM_UNSUPPORTED; } -static int open_f(stream_t *stream, int mode) +static int open_f(stream_t *stream) { stream->fill_buffer = fill_buffer; stream->seek = seek; -- cgit v1.2.3