yawanng updated this revision to Diff 110758.
https://reviews.llvm.org/D35362
Files:
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/CloexecAcceptCheck.cpp
clang-tidy/android/CloexecAcceptCheck.h
docs/ReleaseNotes.rst
docs/clang-tidy/check
yawanng updated this revision to Diff 110755.
https://reviews.llvm.org/D35363
Files:
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/CloexecAccept4Check.cpp
clang-tidy/android/CloexecAccept4Check.h
docs/ReleaseNotes.rst
docs/clang-tidy/che
yawanng added inline comments.
Comment at: clang-tidy/android/CloexecCheck.h:91
+ /// Helper function to get the spelling of a particular argument.
+ StringRef getSpellingArg(const ast_matchers::MatchFinder::MatchResult
&Result,
+ int N) const;
--
yawanng updated this revision to Diff 110753.
yawanng marked an inline comment as done.
https://reviews.llvm.org/D35364
Files:
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/CloexecCheck.cpp
clang-tidy/android/CloexecCheck.h
clang-tidy/andr
yawanng updated this revision to Diff 110752.
https://reviews.llvm.org/D35365
Files:
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/CloexecEpollCreate1Check.cpp
clang-tidy/android/CloexecEpollCreate1Check.h
docs/ReleaseNotes.rst
docs/clan
yawanng updated this revision to Diff 110750.
yawanng marked 2 inline comments as done.
https://reviews.llvm.org/D35368
Files:
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/CloexecInotifyInit1Check.cpp
clang-tidy/android/CloexecInotifyInit1C
yawanng updated this revision to Diff 110751.
https://reviews.llvm.org/D35367
Files:
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/CloexecEpollCreateCheck.cpp
clang-tidy/android/CloexecEpollCreateCheck.h
docs/ReleaseNotes.rst
docs/clang-
yawanng updated this revision to Diff 110749.
yawanng marked an inline comment as done.
https://reviews.llvm.org/D35370
Files:
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/CloexecInotifyInitCheck.cpp
clang-tidy/android/CloexecInotifyInitChe
yawanng updated this revision to Diff 110659.
https://reviews.llvm.org/D35362
Files:
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/CloexecAcceptCheck.cpp
clang-tidy/android/CloexecAcceptCheck.h
docs/ReleaseNotes.rst
docs/clang-tidy/check
yawanng updated this revision to Diff 110655.
https://reviews.llvm.org/D35363
Files:
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/CloexecAccept4Check.cpp
clang-tidy/android/CloexecAccept4Check.h
docs/ReleaseNotes.rst
docs/clang-tidy/che
yawanng updated this revision to Diff 110654.
https://reviews.llvm.org/D35364
Files:
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/CloexecCheck.cpp
clang-tidy/android/CloexecCheck.h
clang-tidy/android/CloexecDupCheck.cpp
clang-tidy/andro
yawanng updated this revision to Diff 110652.
https://reviews.llvm.org/D35365
Files:
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/CloexecEpollCreate1Check.cpp
clang-tidy/android/CloexecEpollCreate1Check.h
docs/ReleaseNotes.rst
docs/clan
yawanng updated this revision to Diff 110650.
https://reviews.llvm.org/D35367
Files:
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/CloexecEpollCreateCheck.cpp
clang-tidy/android/CloexecEpollCreateCheck.h
docs/ReleaseNotes.rst
docs/clang-
yawanng updated this revision to Diff 110649.
https://reviews.llvm.org/D35368
Files:
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/CloexecInotifyInit1Check.cpp
clang-tidy/android/CloexecInotifyInit1Check.h
docs/ReleaseNotes.rst
docs/clan
yawanng updated this revision to Diff 110646.
https://reviews.llvm.org/D35370
Files:
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/CloexecInotifyInitCheck.cpp
clang-tidy/android/CloexecInotifyInitCheck.h
docs/ReleaseNotes.rst
docs/clang-
yawanng added a comment.
https://reviews.llvm.org/rL310669 is the latest and complete version. It fixes
an issue in windows platform.
https://reviews.llvm.org/D35372
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-
yawanng updated this revision to Diff 110640.
yawanng added a comment.
Show full context.
https://reviews.llvm.org/D35743
Files:
lib/Format/TokenAnnotator.cpp
lib/Format/UnwrappedLineParser.cpp
lib/Format/UnwrappedLineParser.h
unittests/Format/FormatTest.cpp
Index: unittests/Format/For
yawanng updated this revision to Diff 110606.
yawanng marked 3 inline comments as done.
https://reviews.llvm.org/D35372
Files:
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/CloexecCheck.cpp
clang-tidy/android/CloexecCheck.h
clang-tidy/andr
yawanng updated this revision to Diff 110443.
yawanng marked 5 inline comments as done.
https://reviews.llvm.org/D35372
Files:
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/CloexecCheck.cpp
clang-tidy/android/CloexecCheck.h
clang-tidy/andr
yawanng added a comment.
In https://reviews.llvm.org/D35372#834238, @hokein wrote:
> Looks good to me, a few nits. Thanks for improving it continuously.
>
> I'd hold it for a while to see whether @alexfh has further comments before
> submitting it.
Thank you for the reviewing :-)
https://rev
yawanng updated this revision to Diff 110065.
yawanng marked 4 inline comments as done.
https://reviews.llvm.org/D35372
Files:
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/CloexecCheck.cpp
clang-tidy/android/CloexecCheck.h
clang-tidy/andr
yawanng added inline comments.
Comment at: clang-tidy/android/CloexecCheck.h:72
+ StringRef getSpellingArg(const ast_matchers::MatchFinder::MatchResult
&Result,
+ int n);
+
hokein wrote:
> `n` should be capital `N`. I think we can make
yawanng updated this revision to Diff 109778.
yawanng marked 13 inline comments as done.
https://reviews.llvm.org/D35372
Files:
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/CloexecCheck.cpp
clang-tidy/android/CloexecCheck.h
clang-tidy/and
yawanng added inline comments.
Comment at: clang-tidy/android/CloexecCheck.h:35
+
+ // This issue has three types.
+ // Type1 is to insert the necessary macro flag in the flag argument.
hokein wrote:
> It is unclear to me what the "issue" means here? I assume t
yawanng updated this revision to Diff 109589.
yawanng marked 9 inline comments as done.
https://reviews.llvm.org/D35372
Files:
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/CloexecCheck.cpp
clang-tidy/android/CloexecCheck.h
clang-tidy/andr
yawanng updated this revision to Diff 109222.
yawanng added a comment.
Move tests to unitest and fix a bug.
https://reviews.llvm.org/D35743
Files:
lib/Format/TokenAnnotator.cpp
lib/Format/UnwrappedLineParser.cpp
lib/Format/UnwrappedLineParser.h
unittests/Format/FormatTest.cpp
Index: un
yawanng added a comment.
Ping.
https://reviews.llvm.org/D35743
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
yawanng added a comment.
Ping.
https://reviews.llvm.org/D35372
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
yawanng updated this revision to Diff 108665.
yawanng marked 3 inline comments as done.
https://reviews.llvm.org/D34114
Files:
lib/AST/RecordLayoutBuilder.cpp
test/CodeGenCXX/warn-padded-packed.cpp
Index: test/CodeGenCXX/warn-padded-packed.cpp
yawanng updated this revision to Diff 108555.
yawanng marked an inline comment as done.
yawanng edited the summary of this revision.
yawanng added a comment.
Add more tests and restrict the conditions.
https://reviews.llvm.org/D34114
Files:
lib/AST/RecordLayoutBuilder.cpp
test/CodeGenCXX/wa
yawanng updated this revision to Diff 108513.
yawanng marked 2 inline comments as done.
yawanng edited the summary of this revision.
https://reviews.llvm.org/D34114
Files:
lib/AST/RecordLayoutBuilder.cpp
test/CodeGenCXX/warn-padded-packed.cpp
Index: test/CodeGenCXX/warn-padded-packed.cpp
===
yawanng updated this revision to Diff 108401.
yawanng added a comment.
Add more tests.
https://reviews.llvm.org/D34114
Files:
lib/AST/RecordLayoutBuilder.cpp
test/CodeGenCXX/warn-padded-packed.cpp
Index: test/CodeGenCXX/warn-padded-packed.cpp
===
yawanng updated this revision to Diff 108397.
https://reviews.llvm.org/D34114
Files:
lib/AST/RecordLayoutBuilder.cpp
test/CodeGenCXX/warn-padded-packed.cpp
Index: test/CodeGenCXX/warn-padded-packed.cpp
===
--- test/CodeGenCXX/w
yawanng updated this revision to Diff 108395.
yawanng edited the summary of this revision.
yawanng added a comment.
Including cases '__attribute__((packed, aligned(X)));'. When the alignment
before packing is less or equal to the packed one, he 'packed' attribute not
including 'aligned(X)' seems
yawanng added inline comments.
Comment at: lib/AST/RecordLayoutBuilder.cpp:1888
-if (Packed && UnpackedAlignment > CharUnits::One() &&
-getSize() == UnpackedSize)
Diag(D->getLocation(), diag::warn_unnecessary_packed)
chh wrote:
> Why not keepi
yawanng added a comment.
In https://reviews.llvm.org/D34114#800253, @rsmith wrote:
> Some concrete suggestions throughout the patch, but I think we should take a
> step back and reconsider this warning approach: it seems bizarre for us to
> warn on any packed struct that happens to contain a `c
yawanng updated this revision to Diff 108380.
yawanng edited the summary of this revision.
yawanng added a comment.
Change the condition of this unnecessary packed warning to when the alignment
of the class is one byte. Remove all field-level warning.
https://reviews.llvm.org/D34114
Files:
l
yawanng added a comment.
Ping
https://reviews.llvm.org/D35372
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
yawanng created this revision.
yawanng added a project: clang-tools-extra.
Herald added a subscriber: klimek.
Add handling for Structured binding declaration in C++17 in clang-format. For
example:
auto [x,y] = a;
auto &[xr, yr] = a;
auto &&[xrr, yrr] = a;
https://reviews.llvm.org/D35743
File
yawanng updated this revision to Diff 107557.
yawanng added a comment.
Refactor the check, add a base class for it, which can facilitate all other
similar checks. Basically, all checks in the same category will have only one
or two lines code by inheriting the base class. If this looks good, I w
yawanng added a comment.
In https://reviews.llvm.org/D35372#810525, @alexfh wrote:
> In https://reviews.llvm.org/D35372#810457, @alexfh wrote:
>
> > I have deja vu ;)
> >
> > Should we make a single check for all CLOEXEC and friends with a single
> > configurable list of (function name, flag nam
yawanng updated this revision to Diff 106539.
yawanng marked an inline comment as done.
Herald added subscribers: xazax.hun, JDevlieghere.
https://reviews.llvm.org/D35367
Files:
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/CloexecEpollCreateC
yawanng updated this revision to Diff 106523.
yawanng marked 2 inline comments as done.
https://reviews.llvm.org/D35365
Files:
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/CloexecEpollCreate1Check.cpp
clang-tidy/android/CloexecEpollCreate1C
yawanng updated this revision to Diff 106520.
yawanng marked an inline comment as done.
Herald added subscribers: xazax.hun, JDevlieghere.
https://reviews.llvm.org/D35368
Files:
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/CloexecInotifyInit1
yawanng updated this revision to Diff 106517.
yawanng marked an inline comment as done.
https://reviews.llvm.org/D35370
Files:
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/CloexecInotifyInitCheck.cpp
clang-tidy/android/CloexecInotifyInitChe
yawanng updated this revision to Diff 106515.
yawanng marked an inline comment as done.
https://reviews.llvm.org/D35372
Files:
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/CloexecMemfdCreateCheck.cpp
clang-tidy/android/CloexecMemfdCreateChe
yawanng created this revision.
yawanng added a project: clang-tools-extra.
Herald added subscribers: xazax.hun, JDevlieghere, mgorny.
accept() is better to be replaced by accept4() with SOCK_CLOEXEC flag to avoid
file descriptor leakage.
This is one of a bunch of similar APIs as below and they h
This revision was automatically updated to reflect the committed changes.
Closed by commit rL307818: [clang-tidy] Add a new Android check
"android-cloexec-socket" (authored by yawanng).
Changed prior to commit:
https://reviews.llvm.org/D34913?vs=106058&id=106252#toc
Repository:
rL LLVM
http
yawanng added a comment.
In https://reviews.llvm.org/D34913#797577, @Eugene.Zelenko wrote:
> Please wait for Alexander, Aaron or Haojian approval.
Could you please check this CL? Thank you.
https://reviews.llvm.org/D34913
___
cfe-commits mailing
yawanng updated this revision to Diff 106058.
yawanng marked 4 inline comments as done.
https://reviews.llvm.org/D34913
Files:
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/CloexecOpenCheck.cpp
clang-tidy/android/CloexecSocketCheck.cpp
cla
yawanng added a comment.
LGTM. Please wait for Alexander approval.
Comment at: clang-apply-replacements/lib/Tooling/ApplyReplacements.cpp:296
+ << "' doesn't exist. Ignoring...\n";
+}
continue;
Maybe add some error message here
yawanng added inline comments.
Comment at: clang-tidy/utils/ASTUtils.h:27
+/// or | | ...
+bool hasFlag(const Expr *Flags, const SourceManager &SM,
+ const LangOptions &LangOpts, const char *CloseOnExecFlag);
alexfh wrote:
> `hasFlag` is too generi
yawanng updated this revision to Diff 105878.
yawanng marked 5 inline comments as done.
https://reviews.llvm.org/D34913
Files:
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/CloexecOpenCheck.cpp
clang-tidy/android/CloexecSocketCheck.cpp
cla
yawanng added a comment.
PING
Repository:
rL LLVM
https://reviews.llvm.org/D34114
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
yawanng updated this revision to Diff 105293.
yawanng marked 8 inline comments as done.
https://reviews.llvm.org/D34913
Files:
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/CloexecOpenCheck.cpp
clang-tidy/android/CloexecSocketCheck.cpp
cla
yawanng created this revision.
yawanng added a project: clang-tools-extra.
Herald added subscribers: xazax.hun, JDevlieghere, mgorny, srhines.
socket() is better to include SOCK_CLOEXEC in its type argument to avoid the
file descriptor leakage.
Repository:
rL LLVM
https://reviews.llvm.org/D3
yawanng updated this revision to Diff 104709.
yawanng added a comment.
Change the file name in toctree.
https://reviews.llvm.org/D34633
Files:
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/CloexecOpenCheck.cpp
clang-tidy/android/CloexecOpe
yawanng updated this revision to Diff 104689.
yawanng added a comment.
Pull back the previous change. For some reason it's lost.
https://reviews.llvm.org/D34633
Files:
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/CloexecOpenCheck.cpp
clan
yawanng updated this revision to Diff 104574.
yawanng added a comment.
Herald added subscribers: mgorny, srhines.
rename the check.
https://reviews.llvm.org/D34633
Files:
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/CloexecOpenCheck.cpp
c
yawanng created this revision.
yawanng added a project: clang-tools-extra.
Herald added subscribers: xazax.hun, JDevlieghere.
Handle a case when the function is passed as an argument of a function-like
macro. Plus fix a format that was forgotten to commit last time.
Repository:
rL LLVM
https
yawanng updated this revision to Diff 103068.
yawanng marked 3 inline comments as done.
https://reviews.llvm.org/D33304
Files:
clang-tidy/CMakeLists.txt
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/FileOpenFlagCheck.cpp
clang-tidy/android
yawanng added a comment.
Ping.
Repository:
rL LLVM
https://reviews.llvm.org/D34114
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
yawanng updated this revision to Diff 102690.
yawanng added a comment.
Format change.
https://reviews.llvm.org/D33304
Files:
clang-tidy/CMakeLists.txt
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/FileOpenFlagCheck.cpp
clang-tidy/android
yawanng updated this revision to Diff 102577.
yawanng marked 7 inline comments as done.
https://reviews.llvm.org/D33304
Files:
clang-tidy/CMakeLists.txt
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/FileOpenFlagCheck.cpp
clang-tidy/android
yawanng added inline comments.
Comment at: clang-tidy/android/FileOpenFlagCheck.cpp:61
+ SourceLocation EndLoc =
+ Lexer::getLocForEndOfToken(FlagArg->getLocEnd(), 0, SM, getLangOpts());
+
hokein wrote:
> Instead of using getLangOpts(), you should use `Resu
yawanng added inline comments.
Comment at: docs/clang-tidy/checks/android-file-open-flag.rst:6
+
+A common source of security bugs has been code that opens file without using
+the ``O_CLOEXEC`` flag. Without that flag, an opened sensitive file would
alexfh wrote
yawanng updated this revision to Diff 102064.
yawanng marked 6 inline comments as done.
https://reviews.llvm.org/D33304
Files:
clang-tidy/CMakeLists.txt
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/FileOpenFlagCheck.cpp
clang-tidy/android
yawanng updated this revision to Diff 101834.
yawanng marked an inline comment as done.
https://reviews.llvm.org/D34002
Files:
clang-tidy/misc/NoexceptMoveConstructorCheck.cpp
test/clang-tidy/misc-noexcept-move-constructor.cpp
Index: test/clang-tidy/misc-noexcept-move-constructor.cpp
==
yawanng updated this revision to Diff 101831.
yawanng marked an inline comment as done.
https://reviews.llvm.org/D33304
Files:
clang-tidy/CMakeLists.txt
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/FileOpenFlagCheck.cpp
clang-tidy/android
yawanng updated this revision to Diff 101279.
yawanng added a comment.
Format changes.
https://reviews.llvm.org/D33304
Files:
clang-tidy/CMakeLists.txt
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/FileOpenFlagCheck.cpp
clang-tidy/androi
yawanng updated this revision to Diff 101267.
https://reviews.llvm.org/D33304
Files:
clang-tidy/CMakeLists.txt
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/FileOpenFlagCheck.cpp
clang-tidy/android/FileOpenFlagCheck.h
clang-tidy/plugin/C
yawanng updated this revision to Diff 100934.
yawanng edited the summary of this revision.
https://reviews.llvm.org/D33304
Files:
clang-tidy/CMakeLists.txt
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/FileOpenFlagCheck.cpp
clang-tidy/andr
yawanng updated this revision to Diff 100928.
yawanng added a comment.
Split the commit to three ones that each of them contains one. This is the
first part.
https://reviews.llvm.org/D33304
Files:
clang-tidy/CMakeLists.txt
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMake
yawanng added a comment.
In https://reviews.llvm.org/D33304#768731, @alexfh wrote:
> It's awesome to see another two checks, and it seems to justify adding a
> separate module, but I'd prefer the other two checks to be sent for review as
> separate patches to make the review easier and faster.
yawanng updated this revision to Diff 100786.
yawanng marked 8 inline comments as done.
https://reviews.llvm.org/D33304
Files:
clang-tidy/CMakeLists.txt
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/CreatUsageCheck.cpp
clang-tidy/android/C
yawanng updated this revision to Diff 100782.
https://reviews.llvm.org/D33304
Files:
clang-tidy/CMakeLists.txt
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/CreatUsageCheck.cpp
clang-tidy/android/CreatUsageCheck.h
clang-tidy/android/File
yawanng added a comment.
Hi, I have updated this CL for review. Thank you very much :)
https://reviews.llvm.org/D33304
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
yawanng updated this revision to Diff 100777.
yawanng added a comment.
Modify the detection algorithm. Add another two checks and corresponding tests
as well as the docs.
https://reviews.llvm.org/D33304
Files:
clang-tidy/CMakeLists.txt
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/
yawanng added a comment.
I will make some major changes to this CL based on the current suggestions from
reviewers and update it for further review later. Thank you for the valuable
advice.
Repository:
rL LLVM
https://reviews.llvm.org/D33304
__
yawanng added a comment.
In https://reviews.llvm.org/D33304#758871, @aaron.ballman wrote:
> In https://reviews.llvm.org/D33304#758808, @alexfh wrote:
>
> > In https://reviews.llvm.org/D33304#758713, @aaron.ballman wrote:
> >
> > > In https://reviews.llvm.org/D33304#758624, @srhines wrote:
> > >
>
yawanng marked an inline comment as done.
yawanng added inline comments.
Comment at: clang-tidy/android/FileDescriptorCheck.cpp:76
+int64_t val = aPInt.getSExtValue();
+if((val & O_CLOEXEC) == 0)
+ return false;
srhines wrote:
> Using O_CLOEXEC here
yawanng updated this revision to Diff 99447.
https://reviews.llvm.org/D33304
Files:
clang-tidy/CMakeLists.txt
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/FileDescriptorCheck.cpp
clang-tidy/android/FileDescriptorCheck.h
clang-tidy/plugi
yawanng updated this revision to Diff 99374.
yawanng added a comment.
Add unit test file.
https://reviews.llvm.org/D33304
Files:
clang-tidy/CMakeLists.txt
clang-tidy/android/AndroidTidyModule.cpp
clang-tidy/android/CMakeLists.txt
clang-tidy/android/FileDescriptorCheck.cpp
clang-tidy/a
yawanng created this revision.
yawanng added a project: clang-tools-extra.
Herald added subscribers: krytarowski, xazax.hun, mgorny, srhines.
A common source of security bugs has been code that opens file descriptors
without using the O_CLOEXEC flag. (Without that flag, an opened sensitive file
yawanng updated this revision to Diff 98705.
yawanng added a comment.
Add more tests.
https://reviews.llvm.org/D33103
Files:
clang-tidy/llvm/TwineLocalCheck.cpp
test/clang-tidy/llvm-twine-local.cpp
Index: test/clang-tidy/llvm-twine-local.cpp
===
yawanng updated this revision to Diff 98684.
https://reviews.llvm.org/D33103
Files:
clang-tidy/llvm/TwineLocalCheck.cpp
test/clang-tidy/llvm-twine-local.cpp
Index: test/clang-tidy/llvm-twine-local.cpp
===
--- test/clang-tidy/ll
86 matches
Mail list logo