Skip to content
This repository was archived by the owner on Sep 2, 2022. It is now read-only.

6766844: ByteArrayInputStream#read with a byte array of length 0 not consistent with InputStream when at EOF #189

Closed
wants to merge 2 commits into from

Conversation

bplb
Copy link
Member

@bplb bplb commented Jun 30, 2021

Modify the specification of java.io.ByteArrayInputStream#read(byte[],int,int) to indicate that -1 is returned instead of 0 when the stream is at its end and the third parameter, len, is zero.


Progress

  • Change must not contain extraneous whitespace
  • Commit message must refer to an issue
  • Change must be properly reviewed

Issue

  • JDK-6766844: ByteArrayInputStream#read with a byte array of length 0 not consistent with InputStream when at EOF

Reviewers

Reviewing

Using git

Checkout this PR locally:
$ git fetch https://git.openjdk.java.net/jdk17 pull/189/head:pull/189
$ git checkout pull/189

Update a local copy of the PR:
$ git checkout pull/189
$ git pull https://git.openjdk.java.net/jdk17 pull/189/head

Using Skara CLI tools

Checkout this PR locally:
$ git pr checkout 189

View PR using the GUI difftool:
$ git pr show -t 189

Using diff file

Download this PR as a diff file:
https://git.openjdk.java.net/jdk17/pull/189.diff

@bplb
Copy link
Member Author

bplb commented Jun 30, 2021

This PR supersedes PR 4591.

@bridgekeeper
Copy link

bridgekeeper bot commented Jun 30, 2021

👋 Welcome back bpb! A progress list of the required criteria for merging this PR into master will be added to the body of your pull request. There are additional pull request commands available for use with this pull request.

@openjdk
Copy link

openjdk bot commented Jun 30, 2021

@bplb The following label will be automatically applied to this pull request:

  • core-libs

When this pull request is ready to be reviewed, an "RFR" email will be sent to the corresponding mailing list. If you would like to change these labels, use the /label pull request command.

@openjdk openjdk bot added the core-libs core-libs-dev@openjdk.java.net label Jun 30, 2021
@mlbridge
Copy link

mlbridge bot commented Jun 30, 2021

Webrevs

@bplb
Copy link
Member Author

bplb commented Jun 30, 2021

/csr

@openjdk
Copy link

openjdk bot commented Jun 30, 2021

@bplb the issue for this pull request, JDK-6766844, already has an approved CSR request: JDK-8269399

@openjdk
Copy link

openjdk bot commented Jul 2, 2021

@bplb This change now passes all automated pre-integration checks.

ℹ️ This project also has non-automated pre-integration requirements. Please see the file CONTRIBUTING.md for details.

After integration, the commit message for the final commit will be:

6766844: ByteArrayInputStream#read with a byte array of length 0 not consistent with InputStream when at EOF

Reviewed-by: naoto, lancea, joehw

You can use pull request commands such as /summary, /contributor and /issue to adjust it as needed.

At the time when this comment was updated there had been 70 new commits pushed to the master branch:

  • 97e0e9e: 8268775: Password is being converted to String in AccessibleJPasswordField
  • 1c18f91: 8269768: JFR Terminology Refresh
  • 6f0e8e7: 8269775: compiler/codegen/ClearArrayTest.java failed with "assert(false) failed: bad AD file"
  • c4ea13e: 8269543: The warning for System::setSecurityManager should only appear once for each caller
  • 2db9005: 8262017: C2: assert(n != __null) failed: Bad immediate dominator info.
  • 7bc96db: 8269771: assert(tmp == _callprojs.fallthrough_catchproj) failed: allocation control projection
  • 5644c4f: 8265132: C2 compilation fails with assert "missing precedence edge"
  • a4d2a9a: 8269745: [JVMCI] restore original qualified exports to Graal
  • e377397: 8268566: java/foreign/TestResourceScope.java timed out
  • 6c76e77: 8260684: vmTestbase/gc/gctests/PhantomReference/phantom002/TestDescription.java timed out
  • ... and 60 more: https://git.openjdk.java.net/jdk17/compare/7e96318a1fb083d1c037c2c8d5a26f68fddf7a04...master

As there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid this automatic rebasing, please check the documentation for the /integrate command for further details.

➡️ To integrate this PR with the above commit message to the master branch, type /integrate in a new comment.

@openjdk openjdk bot added the ready Pull request is ready to be integrated label Jul 2, 2021
@bplb
Copy link
Member Author

bplb commented Jul 8, 2021

/integrate

@openjdk
Copy link

openjdk bot commented Jul 8, 2021

Going to push as commit f46a917.
Since your change was applied there have been 95 commits pushed to the master branch:

  • 9e75f92: 8269738: AssertionError when combining pattern matching and function closure
  • 168af2e: 8269828: corrections in some instruction patterns for KNL x86 platform
  • fa08cc6: 8268766: Desugaring of pattern matching enum switch should be improved
  • 4f70759: 8270006: Switches with 'case null:' should be exhaustive
  • 8f798b8: 8269746: C2: assert(!in->is_CFG()) failed: CFG Node with no controlling input?
  • c812bbb: 8269929: (test) Add diagnostic info to ProceessBuilder/Basic.java for unexpected output
  • 6000950: 8269185: Directories in /opt/runtimepackagetest and /path/to/jdk-17 are different
  • 1f2bf1d: 8269879: [PPC64] C2: Math.rint intrinsic uses wrong rounding mode
  • 7fcd5ca: 8266036: class file for sun.misc.Contended not found
  • a49b1dc: 8269772: [macos-aarch64] test compilation failed with "SocketException: No buffer space available"
  • ... and 85 more: https://git.openjdk.java.net/jdk17/compare/7e96318a1fb083d1c037c2c8d5a26f68fddf7a04...master

Your commit was automatically rebased without conflicts.

@openjdk openjdk bot closed this Jul 8, 2021
@openjdk openjdk bot added integrated Pull request has been integrated and removed ready Pull request is ready to be integrated rfr Pull request is ready for review labels Jul 8, 2021
@openjdk
Copy link

openjdk bot commented Jul 8, 2021

@bplb Pushed as commit f46a917.

💡 You may see a message that your pull request was closed with unmerged commits. This can be safely ignored.

@bplb bplb deleted the ByteArrayInputStream-read-6766844 branch July 14, 2021 16:04
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
core-libs core-libs-dev@openjdk.java.net integrated Pull request has been integrated
Development

Successfully merging this pull request may close these issues.

4 participants