From: Andre Noll Date: Sun, 8 Mar 2009 18:58:08 +0000 (+0100) Subject: oggdec: Abort on input errors. X-Git-Tag: v0.3.4~49 X-Git-Url: http://git.tue.mpg.de/?a=commitdiff_plain;h=18b58a352f2d8ec59442bc4323fbbcc09cb06d7c;p=paraslash.git oggdec: Abort on input errors. --- diff --git a/oggdec_filter.c b/oggdec_filter.c index 8d1abb99..b158a5e1 100644 --- a/oggdec_filter.c +++ b/oggdec_filter.c @@ -125,7 +125,9 @@ static ssize_t ogg_convert(char *inbuffer, size_t len, struct filter_node *fn) if (!pod->vf) { int ib = 1024 * conf->initial_buffer_arg; /* initial buffer */ - if (len fc->input_error) { + if (*fn->fc->input_error < 0) + return *fn->fc->input_error; + if (len < ib) { PARA_DEBUG_LOG("initial input buffer %zd/%d, " "waiting for more data\n", len, ib); return 0;