25 lines
906 B
Diff
25 lines
906 B
Diff
|
From 72bbfc1ecd58f7732946719a0aeb2070f056bb6f Mon Sep 17 00:00:00 2001
|
||
|
From: =?UTF-8?q?Matej=20Mu=C5=BEila?= <mmuzila@redhat.com>
|
||
|
Date: Tue, 16 May 2023 13:04:55 +0200
|
||
|
Subject: [PATCH] (CVE-2022-48281) tiffcrop: Correct simple copy paste error.
|
||
|
Fix #488.
|
||
|
|
||
|
(cherry picked from commit d1b6b9c1b3cae2d9e37754506c1ad8f4f7b646b5)
|
||
|
---
|
||
|
tools/tiffcrop.c | 2 +-
|
||
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
||
|
|
||
|
diff --git a/tools/tiffcrop.c b/tools/tiffcrop.c
|
||
|
index 848b2b49..7f738d91 100644
|
||
|
--- a/tools/tiffcrop.c
|
||
|
+++ b/tools/tiffcrop.c
|
||
|
@@ -7537,7 +7537,7 @@ processCropSelections(struct image_data *image, struct crop_mask *crop,
|
||
|
crop_buff = (unsigned char *)_TIFFmalloc(cropsize);
|
||
|
else
|
||
|
{
|
||
|
- prev_cropsize = seg_buffs[0].size;
|
||
|
+ prev_cropsize = seg_buffs[i].size;
|
||
|
if (prev_cropsize < cropsize)
|
||
|
{
|
||
|
next_buff = _TIFFrealloc(crop_buff, cropsize);
|