[clang-tools-extra] [NFC] Fix potential nullptr dereference. (PR #138283)

Zahira Ammarguellat via cfe-commits cfe-commits at lists.llvm.org
Fri May 2 09:09:41 PDT 2025


zahiraam wrote:

> Did you run code sanitizer over all clang-tidy code or you only interested in this particular file? I think there are many more places where such `nullptr` dereference can happen, e.g.
> 
> https://github.com/llvm/llvm-project/blob/52d2b589b2d7adc3e2b4ea503df4131e088de61f/clang-tools-extra/clang-tidy/bugprone/InaccurateEraseCheck.cpp#L39-L43
> 
> 
> https://github.com/llvm/llvm-project/blob/52d2b589b2d7adc3e2b4ea503df4131e088de61f/clang-tools-extra/clang-tidy/bugprone/IncorrectRoundingsCheck.cpp#L51-L52

Probably. But we usually stick to the potential issues suggested by the sanitizer.

https://github.com/llvm/llvm-project/pull/138283


More information about the cfe-commits mailing list