()
| 130 | |
| 131 | # Control-flow enforcement technology |
| 132 | def cet_protection(): |
| 133 | cflags = sysconfig.get_config_var('CFLAGS') |
| 134 | if not cflags: |
| 135 | return False |
| 136 | flags = cflags.split() |
| 137 | # True if "-mcet -fcf-protection" options are found, but false |
| 138 | # if "-fcf-protection=none" or "-fcf-protection=return" is found. |
| 139 | return (('-mcet' in flags) |
| 140 | and any((flag.startswith('-fcf-protection') |
| 141 | and not flag.endswith(("=none", "=return"))) |
| 142 | for flag in flags)) |
| 143 | CET_PROTECTION = cet_protection() |
| 144 | |
| 145 |
no test coverage detected
searching dependent graphs…