[clang] [clang][analyzer] fix false positive of BlockInCriticalSectionChecker (PR #126752)
via cfe-commits
cfe-commits at lists.llvm.org
Wed Feb 12 06:08:38 PST 2025
flovent wrote:
i have implemented the way using set successfully in my local development environment as @Xazax-hun suggested.
the implementation detail is:
1. when we encounter `open` call, if open flag contains O_NONBLOCK, store call's return Symbol to set,
2. when we encounter `read` call, check whether file descriptor's Symbol exists in this set, if so don't report.
it's different with your solution in the related issue, and it doesn't handle situation when open return -1. have any thoughts for the discussion above? @steakhal
https://github.com/llvm/llvm-project/pull/126752
More information about the cfe-commits
mailing list