[libpng16] Undo failed attempt to debug UMR in png_set_text_2().
This commit is contained in:
parent
7d40b53fbf
commit
d7edcc40e4
12
pngset.c
12
pngset.c
@ -837,9 +837,6 @@ png_set_text_2(png_const_structrp png_ptr, png_inforp info_ptr,
|
|||||||
size_t lang_len, lang_key_len;
|
size_t lang_len, lang_key_len;
|
||||||
png_textp textp = &(info_ptr->text[info_ptr->num_text]);
|
png_textp textp = &(info_ptr->text[info_ptr->num_text]);
|
||||||
|
|
||||||
int text_is_null=0;
|
|
||||||
int text_0_is_0=0;
|
|
||||||
|
|
||||||
if (text_ptr[i].key == NULL)
|
if (text_ptr[i].key == NULL)
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
@ -884,13 +881,8 @@ png_set_text_2(png_const_structrp png_ptr, png_inforp info_ptr,
|
|||||||
}
|
}
|
||||||
# endif
|
# endif
|
||||||
|
|
||||||
if (text_ptr[i].text == NULL)
|
/* oss-fuzz complains of UMR here */
|
||||||
text_is_null=1;
|
if (text_ptr[i].text == NULL || text_ptr[i].text[0] == '\0')
|
||||||
else if (text_ptr[i].text[0] == '\0') /* FIX THIS */
|
|
||||||
text_0_is_0=1;
|
|
||||||
|
|
||||||
/* oss-fuzz complains of UMR on the reference to text_0_is_0 */
|
|
||||||
if (text_is_null || text_0_is_0)
|
|
||||||
{
|
{
|
||||||
text_length = 0;
|
text_length = 0;
|
||||||
# ifdef PNG_iTXt_SUPPORTED
|
# ifdef PNG_iTXt_SUPPORTED
|
||||||
|
Loading…
Reference in New Issue
Block a user