summaryrefslogtreecommitdiff
path: root/thirdparty/libwebp/demux/demux.c
diff options
context:
space:
mode:
authorvolzhs <volzhs@gmail.com>2017-02-17 23:49:40 +0900
committervolzhs <volzhs@gmail.com>2017-02-17 23:49:40 +0900
commit6de3defe7271441f6e55e1a0ed5e115a92a72606 (patch)
tree70cbb89a4a91a6f4731a4cbfc2792b56c86dddbe /thirdparty/libwebp/demux/demux.c
parent903a3aa5f0e128abb1fb752c10b343b34af8f799 (diff)
Update libwebp to 0.6.0
Diffstat (limited to 'thirdparty/libwebp/demux/demux.c')
-rw-r--r--thirdparty/libwebp/demux/demux.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/thirdparty/libwebp/demux/demux.c b/thirdparty/libwebp/demux/demux.c
index 1cb9bd5780..100eab8c01 100644
--- a/thirdparty/libwebp/demux/demux.c
+++ b/thirdparty/libwebp/demux/demux.c
@@ -25,7 +25,7 @@
#define DMUX_MAJ_VERSION 0
#define DMUX_MIN_VERSION 3
-#define DMUX_REV_VERSION 1
+#define DMUX_REV_VERSION 2
typedef struct {
size_t start_; // start location of the data
@@ -590,7 +590,6 @@ static int CheckFrameBounds(const Frame* const frame, int exact,
static int IsValidExtendedFormat(const WebPDemuxer* const dmux) {
const int is_animation = !!(dmux->feature_flags_ & ANIMATION_FLAG);
- const int is_fragmented = !!(dmux->feature_flags_ & FRAGMENTS_FLAG);
const Frame* f = dmux->frames_;
if (dmux->state_ == WEBP_DEMUX_PARSING_HEADER) return 1;
@@ -598,7 +597,7 @@ static int IsValidExtendedFormat(const WebPDemuxer* const dmux) {
if (dmux->canvas_width_ <= 0 || dmux->canvas_height_ <= 0) return 0;
if (dmux->loop_count_ < 0) return 0;
if (dmux->state_ == WEBP_DEMUX_DONE && dmux->frames_ == NULL) return 0;
- if (is_fragmented) return 0;
+ if (dmux->feature_flags_ & ~ALL_VALID_FLAGS) return 0; // invalid bitstream
while (f != NULL) {
const int cur_frame_set = f->frame_num_;