52e1a6a3e4
EmbeddedObjectRef::GetGraphicStream() creates a writable SvMemoryStream, read the graphics data into it and then returns the stream, which will be afterwards used to decode the graphics. But if the data is broken, incorrect seeking may cause a seek way past the buffer, and since the stream is writable, it would be done and cause problems such as running out of memory. The VersionCompatRead class is one such place that reads size from the stream and then seeks based on the read data. Add SvMemoryStream::MakeReadOnly() that will change the stream to be read-only after the initial read of the data into it. Change-Id: I1d44aabaf73071a691adafa489e65e4f5e3f021d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/137002 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com> |
||
---|---|---|
.. | ||
test_100mm2twips.cxx | ||
test_bigint.cxx | ||
test_color.cxx | ||
test_config.cxx | ||
test_cpu_runtime_detection_AVX2.cxx | ||
test_cpu_runtime_detection_AVX2_check.cxx | ||
test_cpu_runtime_detection_SSE2.cxx | ||
test_cpu_runtime_detection_SSE2_check.cxx | ||
test_cpu_runtime_detection_SSSE3.cxx | ||
test_cpu_runtime_detection_SSSE3_check.cxx | ||
test_cpu_runtime_detection_x86_checks.hxx | ||
test_cpuid.cxx | ||
test_date.cxx | ||
test_fract.cxx | ||
test_fround.cxx | ||
test_GenericTypeSerializer.cxx | ||
test_guid.cxx | ||
test_inetmime.cxx | ||
test_json_writer.cxx | ||
test_minmax.cxx | ||
test_pathutils.cxx | ||
test_poly.cxx | ||
test_rectangle.cxx | ||
test_reversemap.cxx | ||
test_stream.cxx | ||
test_time.cxx | ||
test_urlobj.cxx | ||
test_Wildcard.cxx | ||
test_xmlwalker.cxx | ||
test_xmlwriter.cxx | ||
test_zcodec.cxx |