提交 56c631f5 编写于 作者: L Linus Torvalds

Merge tag 'gcc-plugins-v5.4-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/kees/linux

Pull gcc-plugins fix from Kees Cook:
 "Fix a potential problem in randomize_layout structure auto-selection
  (that was not triggered by any existing kernel structures)"

* tag 'gcc-plugins-v5.4-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/kees/linux:
  randstruct: Check member structs in is_pure_ops_struct()
...@@ -443,13 +443,13 @@ static int is_pure_ops_struct(const_tree node) ...@@ -443,13 +443,13 @@ static int is_pure_ops_struct(const_tree node)
if (node == fieldtype) if (node == fieldtype)
continue; continue;
if (!is_fptr(fieldtype)) if (code == RECORD_TYPE || code == UNION_TYPE) {
return 0; if (!is_pure_ops_struct(fieldtype))
return 0;
if (code != RECORD_TYPE && code != UNION_TYPE)
continue; continue;
}
if (!is_pure_ops_struct(fieldtype)) if (!is_fptr(fieldtype))
return 0; return 0;
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册