From owner-svn-src-stable-10@freebsd.org Sat Feb 11 14:28:31 2017 Return-Path: Delivered-To: svn-src-stable-10@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A63AECDA879; Sat, 11 Feb 2017 14:28:31 +0000 (UTC) (envelope-from eric@vangyzen.net) Received: from smtp.vangyzen.net (hotblack.vangyzen.net [199.48.133.146]) by mx1.freebsd.org (Postfix) with ESMTP id 8E1BA134D; Sat, 11 Feb 2017 14:28:31 +0000 (UTC) (envelope-from eric@vangyzen.net) Received: from ford.home.vangyzen.net (unknown [76.164.15.242]) by smtp.vangyzen.net (Postfix) with ESMTPSA id 2F1F6564DF; Sat, 11 Feb 2017 08:28:24 -0600 (CST) Subject: Re: svn commit: r313632 - in stable/10/contrib/netbsd-tests/lib/libc/gen: . posix_spawn To: Ed Schouten , Ngie Cooper References: <201702110735.v1B7ZROH028648@repo.freebsd.org> Cc: src-committers , svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org From: Eric van Gyzen Message-ID: <65538136-4b19-bc06-f3e0-302ef2fc2359@vangyzen.net> Date: Sat, 11 Feb 2017 08:28:21 -0600 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:45.0) Gecko/20100101 Thunderbird/45.6.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 11 Feb 2017 14:28:31 -0000 On 02/11/2017 03:12, Ed Schouten wrote: > 2017-02-11 8:35 GMT+01:00 Ngie Cooper : >> Note that sys/types.h is required on FreeBSD for kqueue(2), unlike NetBSD > > Which is a bug on its own in my opinion. What do you think of this patch? > > Index: sys/sys/event.h > =================================================================== > --- sys/sys/event.h (revision 313335) > +++ sys/sys/event.h (working copy) > @@ -29,7 +29,8 @@ > #ifndef _SYS_EVENT_H_ > #define _SYS_EVENT_H_ > > -#include > +#include > +#include > > #define EVFILT_READ (-1) > #define EVFILT_WRITE (-2) > @@ -57,11 +58,11 @@ > } while(0) > > struct kevent { > - uintptr_t ident; /* identifier for this event */ > + __uintptr_t ident; /* identifier for this event */ > short filter; /* filter for event */ > - u_short flags; > - u_int fflags; > - intptr_t data; > + unsigned short flags; > + unsigned int fflags; > + __intptr_t data; > void *udata; /* opaque user data identifier */ > }; I would be concerned that app developers would read this definition, ignore the one in the man page, and use the __-prefixed types in their apps. Maybe could be included instead? Otherwise, I think a comment about the __ prefix would be wise. Eric