Uploaded image for project: 'Commons IO'
  1. Commons IO
  2. IO-307

ReaderInputStream#read(byte[] b, int off, int len) should check for valid parameters

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.1
    • Fix Version/s: 2.2
    • Component/s: None
    • Labels:
      None

      Description

      If the buffer is null, the method should throw NPE immediately (rather than letting it occur later)

      If the offset or length are < 0 or would overflow the buffer, then throw IndexOutOfBoundsException with details of the values.

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              sebb@apache.org Sebb
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: