From owner-freebsd-bugs Thu Jul 20 11:37:01 1995 Return-Path: bugs-owner Received: (from majordom@localhost) by freefall.cdrom.com (8.6.11/8.6.6) id LAA18287 for bugs-outgoing; Thu, 20 Jul 1995 11:37:01 -0700 Received: from godzilla.zeta.org.au (godzilla.zeta.org.au [203.2.228.34]) by freefall.cdrom.com (8.6.11/8.6.6) with ESMTP id LAA18281 for ; Thu, 20 Jul 1995 11:36:53 -0700 Received: (from bde@localhost) by godzilla.zeta.org.au (8.6.9/8.6.9) id EAA04386; Fri, 21 Jul 1995 04:32:13 +1000 Date: Fri, 21 Jul 1995 04:32:13 +1000 From: Bruce Evans Message-Id: <199507201832.EAA04386@godzilla.zeta.org.au> To: dillon@blob.best.net, terry@cs.weber.edu Subject: Re: possible ffs_vget() race condition Cc: bugs@FreeBSD.org, davidg@Root.COM, mckusick@McKusick.COM Sender: bugs-owner@FreeBSD.org Precedence: bulk >A lot of the system configuration stuff is bogus/unportable/both. The >use of manifest constants to do the descriptor structs in sysctl.h >is patently bogus. >The CTLTYPE_QUAD definition and the size variant CTLTYPE_INT are both >rather annoying; these should be sized values, and QUAD should probably >not be allowed at all, since 64 bit values are (as yet) intolerably >unportable. Enumerated or defined types are more flexible. You can support an arbitrary number of scalar types or type/representation pairs by converting the values using a routine indexed by the type. >Not to mention the use of a shift of an embeded constant '63' and a -1 >to get the RLIM_INFINITY value in resource.h. >Instead of (~(u_quad_t)0). The shift method has the advantage of giving the correct result :-). You meant ((~(u_quad_t)0) >> 1). This depends on u_quad_t being larger than int. Bruce