From 06ec05447f3926a304b682b35fb3723fef249a2b Mon Sep 17 00:00:00 2001 From: Tor Andersson Date: Fri, 25 Apr 2008 21:27:06 +0200 Subject: Fix potential error in fz_readall realloc buffer trimming. --- stream/stm_misc.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'stream/stm_misc.c') diff --git a/stream/stm_misc.c b/stream/stm_misc.c index 22d993d1..1098c016 100644 --- a/stream/stm_misc.c +++ b/stream/stm_misc.c @@ -124,10 +124,10 @@ fz_readall(fz_buffer **bufp, fz_stream *stm) real->refs = 1; real->ownsdata = 1; - real->bp = buf; - real->rp = buf; - real->wp = buf + pos; - real->ep = buf + pos; + real->bp = newbuf; + real->rp = newbuf; + real->wp = newbuf + pos; + real->ep = newbuf + pos; real->eof = 1; *bufp = real; -- cgit v1.2.3