RFR: 8305922: [aix,linux] Avoid comparing 'this' to nullptr

Tyler Steele tsteele at openjdk.org
Thu Apr 20 21:13:47 UTC 2023


This PR removes the remaining 'this' vs. 'nullptr' checks from osThread_linux.cpp and osThread_aix.cpp which cause a build warning on AIX and Linux (when building with Clang). My grepping finds no other occurrences.

As the warning indicates, `this` cannot be `nullptr` in well-formed C++ code. Previous issues have removed these checks, and I believe it makes sense to do so again in these places.

-------------

Commit messages:
 - Remove lingering this == nullptr checks from osThread_*.cpp

Changes: https://git.openjdk.org/jdk/pull/13448/files
 Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=13448&range=00
  Issue: https://bugs.openjdk.org/browse/JDK-8305922
  Stats: 2 lines in 2 files changed: 0 ins; 2 del; 0 mod
  Patch: https://git.openjdk.org/jdk/pull/13448.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/13448/head:pull/13448

PR: https://git.openjdk.org/jdk/pull/13448


More information about the hotspot-runtime-dev mailing list