Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 6 Jul 2020 22:39:42 +0000 (UTC)
From:      Brooks Davis <brooks@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r362979 - head/cddl/contrib/opensolaris/tools/ctf/cvt
Message-ID:  <202007062239.066MdgeD011217@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: brooks
Date: Mon Jul  6 22:39:42 2020
New Revision: 362979
URL: https://svnweb.freebsd.org/changeset/base/362979

Log:
  Fix a Wvoid-pointer-to-enum-cast warning missed in r359978.
  
  This pattern is used in callbacks with void * data arguments and seems
  both relatively uncommon and relatively harmless.  Silence the warning
  by casting through uintptr_t.
  
  This warning is on by default in Clang 11.
  
  MFC after:	3 days
  Sponsored by:	DARPA
  Differential Revision:	https://reviews.freebsd.org/D24425

Modified:
  head/cddl/contrib/opensolaris/tools/ctf/cvt/iidesc.c

Modified: head/cddl/contrib/opensolaris/tools/ctf/cvt/iidesc.c
==============================================================================
--- head/cddl/contrib/opensolaris/tools/ctf/cvt/iidesc.c	Mon Jul  6 21:39:14 2020	(r362978)
+++ head/cddl/contrib/opensolaris/tools/ctf/cvt/iidesc.c	Mon Jul  6 22:39:42 2020	(r362979)
@@ -179,7 +179,7 @@ int
 iidesc_count_type(void *data, void *private)
 {
 	iidesc_t *ii = data;
-	iitype_t match = (iitype_t)private;
+	iitype_t match = (iitype_t)(uintptr_t)private;
 
 	return (ii->ii_type == match);
 }



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