Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 28 Jul 2018 20:04:40 +0000 (UTC)
From:      Alan Somers <asomers@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r336838 - in head/lib: libauditd libbsm
Message-ID:  <201807282004.w6SK4emt021332@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: asomers
Date: Sat Jul 28 20:04:39 2018
New Revision: 336838
URL: https://svnweb.freebsd.org/changeset/base/336838

Log:
  Disable -Wcast-align in libbsm and libauditd
  
  Along with some pending upstream changes, this will allow raising the WARNS
  level.
  
  Reviewed by:	cem, aniketp
  MFC after:	2 weeks
  Differential Revision:	https://reviews.freebsd.org/D16486

Modified:
  head/lib/libauditd/Makefile
  head/lib/libbsm/Makefile

Modified: head/lib/libauditd/Makefile
==============================================================================
--- head/lib/libauditd/Makefile	Sat Jul 28 19:44:20 2018	(r336837)
+++ head/lib/libauditd/Makefile	Sat Jul 28 20:04:39 2018	(r336838)
@@ -23,3 +23,10 @@ WARNS?=		3
 MAN=
 
 .include <bsd.lib.mk>
+
+# Disable -Wcast-align.  Casting res->ai_addr in auditd_set_host triggers this
+# warning, but it's ok because res->ai_addr must've originally pointed to a
+# sockaddr_in or sockaddr_in6 anyway.
+# Better would be to disable this warning in just that one function, but GCC
+# 4.2 can't do that :( .
+CWARNFLAGS.auditd_lib.c+=	-Wno-cast-align

Modified: head/lib/libbsm/Makefile
==============================================================================
--- head/lib/libbsm/Makefile	Sat Jul 28 19:44:20 2018	(r336837)
+++ head/lib/libbsm/Makefile	Sat Jul 28 20:04:39 2018	(r336838)
@@ -181,3 +181,10 @@ MLINKS=	libbsm.3 bsm.3							\
 	setaudit.2 setaudit_addr.2
 
 .include <bsd.lib.mk>
+
+# Disable -Wcast-align.  Casting sa_local in au_to_socket_ex triggers this
+# warning, but it's ok because sa_local must've originally pointed to a
+# sockaddr_in or sockaddr_in6 anyway.
+# Better would be to disable this warning in just that one function, but GCC
+# 4.2 can't do that :( .
+CWARNFLAGS.bsm_token.c+=	-Wno-cast-align



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201807282004.w6SK4emt021332>