From owner-freebsd-current Mon Jun 1 14:34:07 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id OAA11754 for freebsd-current-outgoing; Mon, 1 Jun 1998 14:34:07 -0700 (PDT) (envelope-from owner-freebsd-current@FreeBSD.ORG) Received: from godzilla.zeta.org.au (godzilla.zeta.org.au [203.15.68.22]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id OAA11581 for ; Mon, 1 Jun 1998 14:33:10 -0700 (PDT) (envelope-from bde@godzilla.zeta.org.au) Received: (from bde@localhost) by godzilla.zeta.org.au (8.8.7/8.8.7) id HAA00254; Tue, 2 Jun 1998 07:33:03 +1000 Date: Tue, 2 Jun 1998 07:33:03 +1000 From: Bruce Evans Message-Id: <199806012133.HAA00254@godzilla.zeta.org.au> To: mike@smith.net.au, wollman@khavrinen.lcs.mit.edu Subject: Re: cdrecord trouble on currnet Cc: freebsd-current@FreeBSD.ORG Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG >> This would defeat the entire purpose of sysconf(), which is to pass >> opaque constants to the kernel. > >Bullshit. Go look at the code before making pronouncements from on >high. > >In particular, note the code which quite clearly states: > > case _SC_CHILD_MAX: > return (getrlimit(RLIMIT_NPROC, &rl) ? -1 : rl.rlim_cur); > case _SC_CLK_TCK: > return (CLK_TCK); > >There is no earthly reason why a: > > case _SC_PAGESIZE: > return (getpagesize()); > >...cannot be added to this same switch statement. Except it gives yet more namespace pollution. Existing namespace pollution can be leveraged by calling sysctl() directly: case _SC_PAGESIZE: mib[0] = CTL_HW; mib[1] = HW_PAGESIZE; break; Bruce To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message