IDEMPIERE-1763 Add Index out of bound checking.
This commit is contained in:
parent
d4ac873530
commit
157b2f1534
|
@ -332,7 +332,7 @@ public class TableElement extends PrintElement
|
||||||
{
|
{
|
||||||
dimensions.set(dataCol, new Dimension2DImpl());
|
dimensions.set(dataCol, new Dimension2DImpl());
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
String string = dataItem.toString();
|
String string = dataItem.toString();
|
||||||
if (string.length() == 0)
|
if (string.length() == 0)
|
||||||
{
|
{
|
||||||
|
@ -1196,6 +1196,9 @@ public class TableElement extends PrintElement
|
||||||
if (pageXindex+1 < m_firstColumnOnPage.size())
|
if (pageXindex+1 < m_firstColumnOnPage.size())
|
||||||
nextPageColumn = ((Integer)m_firstColumnOnPage.get(pageXindex+1)).intValue();
|
nextPageColumn = ((Integer)m_firstColumnOnPage.get(pageXindex+1)).intValue();
|
||||||
//
|
//
|
||||||
|
if (pageYindex >= m_firstRowOnPage.size()) {
|
||||||
|
pageYindex = m_firstRowOnPage.size() - 1;
|
||||||
|
}
|
||||||
int firstRow = ((Integer)m_firstRowOnPage.get(pageYindex)).intValue();
|
int firstRow = ((Integer)m_firstRowOnPage.get(pageYindex)).intValue();
|
||||||
int nextPageRow = m_data.getRowCount(); // no of rows
|
int nextPageRow = m_data.getRowCount(); // no of rows
|
||||||
if (pageYindex+1 < m_firstRowOnPage.size())
|
if (pageYindex+1 < m_firstRowOnPage.size())
|
||||||
|
|
Loading…
Reference in New Issue