danix800 added inline comments.

================
Comment at: clang/lib/StaticAnalyzer/Checkers/MPI-Checker/MPIChecker.cpp:46-48
+    if (!ErrorNode)
+      return;
+
----------------
steakhal wrote:
> If these hunks are not closely related to the issue you intend to fix in this 
> PR, I'd suggesst submitting it separately. That is a common API, and we 
> wouldn't need tests for such defensive checks, as they rarely trigger.
Moved (together with the extra testcase file) into 
https://reviews.llvm.org/D158858.

Checking `ExplodedNode` against nullptr is a convention in almost all checkers. 
It surely can be null (quite often).

`MPIChecker` is one of the only two checkers that forget to do this checking 
and crashed as reported by #64647


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D158813/new/

https://reviews.llvm.org/D158813

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to