New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
8231041: Spotbugs: Null check of value previously dereferenced in java.desktop #1869
8231041: Spotbugs: Null check of value previously dereferenced in java.desktop #1869
Conversation
|
@turbanoff The following labels will be automatically applied to this pull request:
When this pull request is ready to be reviewed, an "RFR" email will be sent to the corresponding mailing lists. If you would like to change these labels, use the /label pull request command. |
Webrevs
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Did it occur that maybe the previous de-reference without a null check is the real problem ?
The proposed Raster change actually needs to be addressed as discussed inhttps://bugs.openjdk.java.net/browse/JDK-8255800 and so should not be part of this proposed change. DataBufferUShort may be the same.
But all of them need to be re-examined rather than just blindly updating them as some tool suggests.
I had a similar fix in past, but the problem here is that most of these exceptions are not specified, or specified differently than actually works. So I postponed the fix since the spec clarification is required. I suggest postponing this PR until then. |
I agree. I actually did careful investigation of all my changes. As you can see SpotBugs reported much more than I actually propose to fix. I reverted most controversal changes from this PR. I hoped that reviewers could help me to clarify controversal changes and start discussion about unclear places. 1.
|
Do you know if this clarification is in progress now? As I see from @prrace comment there is https://bugs.openjdk.java.net/browse/JDK-8255800 Do you know any more similar issues? |
I do not know any other issues except this one. If you wish to continue to work on this bug, then it will be simpler to only change the code where exceptions are already specified, for example, drop the changes in the DataBufferUShort(), etc. |
@turbanoff This pull request has been inactive for more than 4 weeks and will be automatically closed if another 4 weeks passes without any activity. To avoid this, simply add a new comment to the pull request. Feel free to ask for assistance if you need help with progressing this pull request towards integration! |
@turbanoff This pull request has been inactive for more than 8 weeks and will now be automatically closed. If you would like to continue working on this pull request in the future, feel free to reopen it! |
I checked JDK16 repository in SpotBugs 4.2.0

I fixed only places in java.desktop module.
I didn't fixed places, where dereferencing is done inside method.
Progress
Integration blocker
Issue
Download
$ git fetch https://git.openjdk.java.net/jdk pull/1869/head:pull/1869
$ git checkout pull/1869