[PATCH] D88140: [clang-tidy] Check for sigaction in cert-sig30-c.

Balázs Kéri via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Sep 23 02:43:23 PDT 2020


balazske created this revision.
Herald added subscribers: cfe-commits, martong, gamesh411, Szelethus, dkrupp, xazax.hun, whisperity.
Herald added a project: clang.
balazske requested review of this revision.

The checker recognizes handlers assigned to members of a
"struct sigaction" variable. If a function is assigned to
these members it is assumable that the function is used as signal handler
(function 'sigaction' is called with it).
Without this simplification the check is possible only in path-sensitive way.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D88140

Files:
  clang-tools-extra/clang-tidy/cert/SignalHandlerCheck.cpp
  clang-tools-extra/test/clang-tidy/checkers/Inputs/Headers/signal.h
  clang-tools-extra/test/clang-tidy/checkers/cert-sig30-c.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D88140.293677.patch
Type: text/x-patch
Size: 8863 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20200923/1e3386bb/attachment.bin>


More information about the cfe-commits mailing list