Uploaded image for project: 'Wicket'
  1. Wicket
  2. WICKET-2181

Bounds error in PageableListView#getCurrentPage()

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • 1.4-RC3
    • wicket
    • None

    Description

      In the getCurrentPage() method of class PageableListView, the following code:

      while ((currentPage * rowsPerPage) > getList().size())
      {
      currentPage--;
      }

      checks if "first cell if out of range". However, the index of that first cell is (currentPage * rowsPerPage), and then the comparison with getList().size() should use a ">=" instead a ">".

      Attachments

        Activity

          People

            jdonnerstag Juegen Donnerstag
            jluini Julián Mauro Luini
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Time Tracking

                Estimated:
                Original Estimate - 1m
                1m
                Remaining:
                Remaining Estimate - 1m
                1m
                Logged:
                Time Spent - Not Specified
                Not Specified