[PATCH] D35362: [clang-tidy] Add a close-on-exec check on accept() in Android module.
Chih-Hung Hsieh via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed Aug 16 10:14:32 PDT 2017
chh commandeered this revision.
chh added a reviewer: yawanng.
chh added inline comments.
================
Comment at: clang-tidy/android/CloexecAcceptCheck.cpp:42
+ "prefer accept4() to accept() because accept4() allows SOCK_CLOEXEC",
+ /*FixMsg=*/ReplacementText);
+}
----------------
alexfh wrote:
> Two minor issues here:
> 1. `FixMsg` name is misleading, specifically the "Msg" part, since it's not a message.
> 2. there's no need to use an argument comment, where it's clear what the actual argument's meaning is. E.g. `ReplacementText` is pretty clear on its own. As is the warning message above.
Done.
https://reviews.llvm.org/D35362
More information about the cfe-commits
mailing list