mirror of https://github.com/apache/poi.git
hwpf: ignore incorrect ListFormatOverride reference that causes IndexOutOfBoundException
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1064110 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
fa799dd7e2
commit
d86df59b57
|
@ -165,6 +165,10 @@ public final class ListTables
|
|||
return _overrideList.get(lfoIndex - 1);
|
||||
}
|
||||
|
||||
public int getOverrideCount() {
|
||||
return _overrideList.size();
|
||||
}
|
||||
|
||||
public int getOverrideIndexFromListID(int lstid)
|
||||
{
|
||||
int returnVal = -1;
|
||||
|
|
|
@ -37,7 +37,7 @@ public final class ListEntry
|
|||
{
|
||||
super(papx, parent);
|
||||
|
||||
if(tables != null) {
|
||||
if(tables != null && _props.getIlfo() < tables.getOverrideCount()) {
|
||||
ListFormatOverride override = tables.getOverride(_props.getIlfo());
|
||||
_overrideLevel = override.getOverrideLevel(_props.getIlvl());
|
||||
_level = tables.getLevel(override.getLsid(), _props.getIlvl());
|
||||
|
|
Loading…
Reference in New Issue