[bzip2, gzip] Avoid access of unitialized memory (#46109).

* src/bzip2/ftbzip2.c (ft_bzip2_file_fill_output), src/gzip/ftgzip.c
(ft_gzip_file_fill_output): In case of an error, adjust the limit to
avoid copying uninitialized memory.
This commit is contained in:
Werner Lemberg 2015-10-03 21:12:25 +02:00
parent e2dae8fead
commit 53838ce016
3 changed files with 12 additions and 2 deletions

View File

@ -1,3 +1,11 @@
2015-10-03 Werner Lemberg <wl@gnu.org>
[bzip2, gzip] Avoid access of unitialized memory (#46109).
* src/bzip2/ftbzip2.c (ft_bzip2_file_fill_output), src/gzip/ftgzip.c
(ft_gzip_file_fill_output): In case of an error, adjust the limit to
avoid copying uninitialized memory.
2015-10-01 Alexei Podtelezhnikov <apodtele@gmail.com>
[smooth] Clean up worker.

View File

@ -310,7 +310,8 @@
}
else if ( err != BZ_OK )
{
error = FT_THROW( Invalid_Stream_Operation );
zip->limit = zip->cursor;
error = FT_THROW( Invalid_Stream_Operation );
break;
}
}

View File

@ -433,7 +433,8 @@
}
else if ( err != Z_OK )
{
error = FT_THROW( Invalid_Stream_Operation );
zip->limit = zip->cursor;
error = FT_THROW( Invalid_Stream_Operation );
break;
}
}