ofz#49217 Out-of-memory
just abandon in this case Change-Id: I2234f130e3c8de0b044256921f5d6941acc72e59 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/154769 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
This commit is contained in:
parent
27ad68a95b
commit
7e164e4dcd
1 changed files with 6 additions and 1 deletions
|
@ -21,6 +21,7 @@
|
|||
|
||||
#include <comphelper/newarray.hxx>
|
||||
#include <unotools/configmgr.hxx>
|
||||
#include <sal/log.hxx>
|
||||
#include <tools/long.hxx>
|
||||
|
||||
#include <assert.h>
|
||||
|
@ -490,7 +491,11 @@ bool Picture::Read(HWPFile & hwpf)
|
|||
if (nBlock != nReadBlock)
|
||||
break;
|
||||
if (nMaxAllowedDecompression && follow.size() > nMaxAllowedDecompression)
|
||||
break;
|
||||
{
|
||||
SAL_WARN("filter.hwp", "too much decompression, abandoning");
|
||||
follow.clear();
|
||||
return false;
|
||||
}
|
||||
}
|
||||
follow_block_size = follow.size();
|
||||
|
||||
|
|
Loading…
Reference in a new issue