From ef3a5e0aae003c29941c7d41ed6becea4287752d Mon Sep 17 00:00:00 2001 From: =?utf8?q?V=C3=A1clav=20Slav=C3=ADk?= Date: Thu, 22 Nov 2001 23:55:34 +0000 Subject: [PATCH] blind fix for wxGIFDecoder::ReadGIF git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@12608 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/common/gifdecod.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/common/gifdecod.cpp b/src/common/gifdecod.cpp index ffd45bc87e..1cd7e9f827 100644 --- a/src/common/gifdecod.cpp +++ b/src/common/gifdecod.cpp @@ -653,6 +653,9 @@ int wxGIFDecoder::ReadGIF() /* try to read to the end of the stream */ while (type != 0x3B) { + if (!m_f->IsOk()) + return wxGIF_TRUNCATED; + type = (unsigned char)m_f->GetC(); if (type == 0x21) -- 2.50.0