diff options
author | Dominik Stadler <centic@apache.org> | 2013-08-26 20:09:19 +0000 |
---|---|---|
committer | Dominik Stadler <centic@apache.org> | 2013-08-26 20:09:19 +0000 |
commit | 8693b4f9970cecd12df35c0fdc82894162dbb104 (patch) | |
tree | 3a01550337cdc6680c59ffca4b2f31dd5f37ce96 /src/java | |
parent | d3bfcda99e25ae253d17dbae82d3ebd9c9977f03 (diff) | |
download | poi-8693b4f9970cecd12df35c0fdc82894162dbb104.tar.gz poi-8693b4f9970cecd12df35c0fdc82894162dbb104.zip |
Bug 54524: Fix border case in FormulaShifter
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1517676 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src/java')
-rw-r--r-- | src/java/org/apache/poi/ss/formula/FormulaShifter.java | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/java/org/apache/poi/ss/formula/FormulaShifter.java b/src/java/org/apache/poi/ss/formula/FormulaShifter.java index 32da2b17a4..74804a8845 100644 --- a/src/java/org/apache/poi/ss/formula/FormulaShifter.java +++ b/src/java/org/apache/poi/ss/formula/FormulaShifter.java @@ -85,6 +85,7 @@ public final class FormulaShifter { return new FormulaShifter(srcSheetIndex, dstSheetIndex); } + @Override public String toString() { StringBuffer sb = new StringBuffer(); @@ -322,7 +323,7 @@ public final class FormulaShifter { aptg.setFirstRow(destLastRowIndex+1); return aptg; } - if (destFirstRowIndex < aLastRow && aLastRow <= destLastRowIndex) { + if (destFirstRowIndex <= aLastRow && aLastRow < destLastRowIndex) { // dest rows overlap bottom of area // - truncate the bottom aptg.setLastRow(destFirstRowIndex-1); |