File tree Expand file tree Collapse file tree 5 files changed +10
-10
lines changed Expand file tree Collapse file tree 5 files changed +10
-10
lines changed Original file line number Diff line number Diff line change @@ -4,7 +4,7 @@ android-cloexec-pipe
44====================
55
66This check detects usage of ``pipe() ``. Using ``pipe() `` is not recommended,
7- ``pipe2() `` is the suggested replacement. The check also adds the O_CLOEXEC
7+ ``pipe2() `` is the suggested replacement. The check also adds the `` O_CLOEXEC ``
88flag that marks the file descriptor to be closed in child processes.
99Without this flag a sensitive file descriptor can be leaked to a
1010child process, potentially into a lower-privileged SELinux domain.
Original file line number Diff line number Diff line change 33android-cloexec-pipe2
44=====================
55
6- This check ensures that pipe2() is called with the O_CLOEXEC flag.
7- The check also adds the O_CLOEXEC flag that marks the file descriptor
6+ This check ensures that `` pipe2() `` is called with the `` O_CLOEXEC `` flag.
7+ The check also adds the `` O_CLOEXEC `` flag that marks the file descriptor
88to be closed in child processes.
99Without this flag a sensitive file descriptor can be leaked to a child process,
1010potentially into a lower-privileged SELinux domain.
Original file line number Diff line number Diff line change @@ -22,7 +22,7 @@ Example buggy usage looks like:
2222 // Do something with cs.
2323 }
2424
25- Because TEMP_FAILURE_RETRY will check for whether the result
25+ Because `` TEMP_FAILURE_RETRY `` will check for whether the result
2626*of the comparison * is ``-1 ``, and retry if so.
2727
2828If you encounter this, the fix is simple: lift the comparison out of the
Original file line number Diff line number Diff line change @@ -9,7 +9,7 @@ equality tests.
99
1010This check finds all assignments within `if ` conditions, including ones that
1111are not flagged by `-Wparentheses ` due to an extra set of parentheses, and
12- including assignments that call an overloaded `operator=() `. The identified
12+ including assignments that call an overloaded `` operator=() ` `. The identified
1313assignments violate
1414`BARR group "Rule 8.2.c" <https://barrgroup.com/embedded-systems/books/embedded-c-coding-standard/statement-rules/if-else-statements >`_.
1515
Original file line number Diff line number Diff line change @@ -23,11 +23,11 @@ bitmask if the three conditions below are true at the same time:
2323So whenever the non pow-of-2 element is used as a bitmask element we diagnose a
2424misuse and give a warning.
2525
26- 2. Investigating the right hand side of `+= ` and `|= ` operator.
27- 3. Check only the enum value side of a `| ` and `+ ` operator if one of them is
28- not enum val.
29- 4. Check both side of `| ` or `+ ` operator where the enum values are from the
30- same enum type.
26+ 2. Investigating the right hand side of `` += `` and `` |= ` ` operator.
27+ 3. Check only the enum value side of a `` | `` and `` + `` operator if one of
28+ them is not enum val.
29+ 4. Check both side of `` | `` or `` + `` operator where the enum values are from
30+ the same enum type.
3131
3232Examples:
3333
You can’t perform that action at this time.
0 commit comments