diff options
-rw-r--r-- | src/scratchpad/src/org/apache/poi/hslf/usermodel/HSLFTextParagraph.java | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/scratchpad/src/org/apache/poi/hslf/usermodel/HSLFTextParagraph.java b/src/scratchpad/src/org/apache/poi/hslf/usermodel/HSLFTextParagraph.java index 76969a4713..79ca35caf7 100644 --- a/src/scratchpad/src/org/apache/poi/hslf/usermodel/HSLFTextParagraph.java +++ b/src/scratchpad/src/org/apache/poi/hslf/usermodel/HSLFTextParagraph.java @@ -1257,6 +1257,7 @@ public final class HSLFTextParagraph implements TextParagraph<HSLFShape,HSLFText int paraIdx = 0;
for (IndentProp p : paraStyles) {
for (int ccPara = 0, ccStyle = p.getCharactersCovered(); ccPara < ccStyle; paraIdx++) {
+ if (paraIdx >= paragraphs.size() || ccPara >= ccStyle-1) return;
HSLFTextParagraph para = paragraphs.get(paraIdx);
int len = 0;
for (HSLFTextRun trun : para.getTextRuns()) {
|