You've already forked FFmpeg
							
							
				mirror of
				https://github.com/FFmpeg/FFmpeg.git
				synced 2025-10-30 23:18:11 +02:00 
			
		
		
		
	avcodec/gif_parser: split correctly also bitstreams that do not have extension blocks
This commit is contained in:
		| @@ -67,6 +67,17 @@ static int gif_find_frame_end(GIFParseContext *g, const uint8_t *buf, | ||||
|                 g->state = GIF_EXTENSION; | ||||
|                 g->found_start = pc->frame_start_found = 1; | ||||
|             } else if (buf[index] == GIF_IMAGE_SEPARATOR) { | ||||
|                 if (g->state != GIF_EXTENSION_BLOCK && g->found_start && | ||||
|                     g->found_end && g->found_sig) { | ||||
|                     next = index; | ||||
|                     g->found_start = pc->frame_start_found = 1; | ||||
|                     g->found_end = 0; | ||||
|                     g->index = 0; | ||||
|                     g->gct_flag = 0; | ||||
|                     g->gct_size = 0; | ||||
|                     g->state = GIF_IMAGE; | ||||
|                     break; | ||||
|                 } | ||||
|                 g->state = GIF_IMAGE; | ||||
|             } else if (buf[index] == GIF_TRAILER) { | ||||
|                 g->state = 0; | ||||
|   | ||||
		Reference in New Issue
	
	Block a user