Date: Mon, 19 Aug 2019 18:15:17 +0000 (UTC) From: Kyle Evans <kevans@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r351227 - head/sys/mips/include Message-ID: <201908191815.x7JIFHqc012949@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: kevans Date: Mon Aug 19 18:15:17 2019 New Revision: 351227 URL: https://svnweb.freebsd.org/changeset/base/351227 Log: mips: avoid empty mdproc struct Compiling with a more modern toolchain than GCC 4.2 in base warns about the empty struct. Take a hint and comment from r350902+r350953 by luporl@. Modified: head/sys/mips/include/proc.h Modified: head/sys/mips/include/proc.h ============================================================================== --- head/sys/mips/include/proc.h Mon Aug 19 17:54:40 2019 (r351226) +++ head/sys/mips/include/proc.h Mon Aug 19 18:15:17 2019 (r351227) @@ -79,7 +79,8 @@ struct mdthread { #define MDTD_COP2USED 0x0002 /* Process used the COP2 */ struct mdproc { - /* empty */ + /* Avoid empty structs because they are undefined behavior. */ + long md_spare; }; struct syscall_args {
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201908191815.x7JIFHqc012949>