diff options
| author | 2019-11-15 10:30:50 +0100 | |
|---|---|---|
| committer | 2019-11-15 10:30:50 +0100 | |
| commit | ac94be498f84f7327533b62faca4c3da64434904 (patch) | |
| tree | 63893f37afb67cd400bf60ec16a35440d16f2a90 /scripts/gcc-plugins/randomize_layout_plugin.c | |
| parent | x86/hyperv: Allow guests to enable InvariantTSC (diff) | |
| parent | Merge tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm (diff) | |
| download | linux-dev-ac94be498f84f7327533b62faca4c3da64434904.tar.xz linux-dev-ac94be498f84f7327533b62faca4c3da64434904.zip | |
Merge branch 'linus' into x86/hyperv
Pick up upstream fixes to avoid conflicts.
Diffstat (limited to 'scripts/gcc-plugins/randomize_layout_plugin.c')
| -rw-r--r-- | scripts/gcc-plugins/randomize_layout_plugin.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/scripts/gcc-plugins/randomize_layout_plugin.c b/scripts/gcc-plugins/randomize_layout_plugin.c index 6d5bbd31db7f..bd29e4e7a524 100644 --- a/scripts/gcc-plugins/randomize_layout_plugin.c +++ b/scripts/gcc-plugins/randomize_layout_plugin.c @@ -443,13 +443,13 @@ static int is_pure_ops_struct(const_tree node) if (node == fieldtype) continue; - if (!is_fptr(fieldtype)) - return 0; - - if (code != RECORD_TYPE && code != UNION_TYPE) + if (code == RECORD_TYPE || code == UNION_TYPE) { + if (!is_pure_ops_struct(fieldtype)) + return 0; continue; + } - if (!is_pure_ops_struct(fieldtype)) + if (!is_fptr(fieldtype)) return 0; } |
