From 5c1b8d4aa1d35c806159cb22d52449774eb5186e Mon Sep 17 00:00:00 2001 From: wm4 Date: Fri, 12 Jul 2013 22:05:43 +0200 Subject: stream: don't require streams to set a type Set the type only for streams that have special treatment in other parts of the code. --- stream/stream.c | 4 ---- 1 file changed, 4 deletions(-) (limited to 'stream/stream.c') diff --git a/stream/stream.c b/stream/stream.c index 32ae0047be..39fc872169 100644 --- a/stream/stream.c +++ b/stream/stream.c @@ -175,8 +175,6 @@ static stream_t *open_stream_plugin(const stream_info_t *sinfo, s->cache_size = 320; } - if (s->type <= -2) - mp_msg(MSGT_OPEN, MSGL_WARN, "Warning streams need a type !!!!\n"); if (!s->seek) s->flags &= ~MP_STREAM_SEEK; if (s->seek && !(s->flags & MP_STREAM_SEEK)) @@ -595,7 +593,6 @@ static stream_t *new_stream(size_t min_size) memset(s, 0, sizeof(stream_t)); s->fd = -2; - s->type = -2; return s; } @@ -672,7 +669,6 @@ int stream_enable_cache(stream_t **stream, int64_t size, int64_t min, orig->buf_len = orig->buf_pos = 0; stream_t *cache = new_stream(0); - cache->type = STREAMTYPE_CACHE; cache->uncached_type = orig->type; cache->uncached_stream = orig; cache->flags |= MP_STREAM_SEEK; -- cgit v1.2.3