mirror of
https://git.code.sf.net/p/libpng/code.git
synced 2025-07-10 18:04:09 +02:00
[master] Check for out-of-range text compression mode in png_set_text().
This commit is contained in:
parent
f3eadd1737
commit
c0fc0dfc45
7
ANNOUNCE
7
ANNOUNCE
@ -1,5 +1,5 @@
|
|||||||
|
|
||||||
Libpng 1.4.5beta04 - October 8, 2010
|
Libpng 1.4.5beta04 - October 13, 2010
|
||||||
|
|
||||||
This is not intended to be a public release. It will be replaced
|
This is not intended to be a public release. It will be replaced
|
||||||
within a few weeks by a public version or by another test version.
|
within a few weeks by a public version or by another test version.
|
||||||
@ -38,9 +38,10 @@ version 1.4.5beta02 [October 5, 2010]
|
|||||||
|
|
||||||
version 1.4.5beta03 [October 8, 2010]
|
version 1.4.5beta03 [October 8, 2010]
|
||||||
Wrapped long lines in CMakeLists.txt and introduced ${libpng_public_hdrs}
|
Wrapped long lines in CMakeLists.txt and introduced ${libpng_public_hdrs}
|
||||||
Undid Makefile revision of 1.4.5beta02.
|
Undid Makefile.am revision of 1.4.5beta02.
|
||||||
|
|
||||||
version 1.4.5beta04 [October 8, 2010]
|
version 1.4.5beta04 [October 13, 2010]
|
||||||
|
Check for out-of-range text compression mode in png_set_text().
|
||||||
|
|
||||||
Send comments/corrections/commendations to glennrp at users.sourceforge.net
|
Send comments/corrections/commendations to glennrp at users.sourceforge.net
|
||||||
or to png-mng-implement at lists.sf.net (subscription required; visit
|
or to png-mng-implement at lists.sf.net (subscription required; visit
|
||||||
|
|||||||
5
CHANGES
5
CHANGES
@ -2692,9 +2692,10 @@ version 1.4.5beta02 [October 5, 2010]
|
|||||||
|
|
||||||
version 1.4.5beta03 [October 8, 2010]
|
version 1.4.5beta03 [October 8, 2010]
|
||||||
Wrapped long lines in CMakeLists.txt and introduced ${libpng_public_hdrs}
|
Wrapped long lines in CMakeLists.txt and introduced ${libpng_public_hdrs}
|
||||||
Undid Makefile revision of 1.4.5beta02.
|
Undid Makefile.am revision of 1.4.5beta02.
|
||||||
|
|
||||||
version 1.4.5beta04 [October 8, 2010]
|
version 1.4.5beta04 [October 13, 2010]
|
||||||
|
Check for out-of-range text compression mode in png_set_text().
|
||||||
|
|
||||||
Send comments/corrections/commendations to glennrp at users.sourceforge.net
|
Send comments/corrections/commendations to glennrp at users.sourceforge.net
|
||||||
or to png-mng-implement at lists.sf.net (subscription required; visit
|
or to png-mng-implement at lists.sf.net (subscription required; visit
|
||||||
|
|||||||
9
pngset.c
9
pngset.c
@ -1,7 +1,7 @@
|
|||||||
|
|
||||||
/* pngset.c - storage of image information into info struct
|
/* pngset.c - storage of image information into info struct
|
||||||
*
|
*
|
||||||
* Last changed in libpng 1.4.1 [February 25, 2010]
|
* Last changed in libpng 1.4.5 [October 13, 2010]
|
||||||
* Copyright (c) 1998-2010 Glenn Randers-Pehrson
|
* Copyright (c) 1998-2010 Glenn Randers-Pehrson
|
||||||
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
|
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
|
||||||
* (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.)
|
* (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.)
|
||||||
@ -690,6 +690,13 @@ png_set_text_2(png_structp png_ptr, png_infop info_ptr, png_textp text_ptr,
|
|||||||
if (text_ptr[i].key == NULL)
|
if (text_ptr[i].key == NULL)
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
|
if (text_ptr[i].compression < PNG_TEXT_COMPRESSION_NONE ||
|
||||||
|
text_ptr[i].compression >= PNG_TEXT_COMPRESSION_LAST)
|
||||||
|
{
|
||||||
|
png_warning(png_ptr, "text compression mode is out of range");
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
key_len = png_strlen(text_ptr[i].key);
|
key_len = png_strlen(text_ptr[i].key);
|
||||||
|
|
||||||
if (text_ptr[i].compression <= 0)
|
if (text_ptr[i].compression <= 0)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user