From owner-freebsd-bugs Thu Dec 25 20:23:00 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.7/8.8.7) id UAA20921 for bugs-outgoing; Thu, 25 Dec 1997 20:23:00 -0800 (PST) (envelope-from owner-freebsd-bugs) Received: from godzilla.zeta.org.au (godzilla.zeta.org.au [203.2.228.19]) by hub.freebsd.org (8.8.7/8.8.7) with ESMTP id UAA20899; Thu, 25 Dec 1997 20:22:07 -0800 (PST) (envelope-from bde@godzilla.zeta.org.au) Received: (from bde@localhost) by godzilla.zeta.org.au (8.8.7/8.8.7) id PAA06178; Fri, 26 Dec 1997 15:11:23 +1100 Date: Fri, 26 Dec 1997 15:11:23 +1100 From: Bruce Evans Message-Id: <199712260411.PAA06178@godzilla.zeta.org.au> To: dima@tejblum.dnttm.rssi.ru, hoek@FreeBSD.ORG Subject: Re: kern/2412 Cc: freebsd-bugs@FreeBSD.ORG, h-nokubi@nmit.mt.nec.co.jp Sender: owner-freebsd-bugs@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk >Rather than trying to guess wether the code is meant to be >compiled or is just stale, I'll move it into feedback and just >double-check that USER_LDT was supposed to have been configured. > >Is there someone specific responsible for the USER_LDT stuff who >would be aware of potentially wrong code, or is it worth leaving >the pr open just for that? No one specific is responsible, but USER_LDT is obviously quite broken without the option being visible. fork(), exec() and exit() are broken. fork()ing with an active user LDT at best leaves 2 processes sharing the LDT. exec()ing with an active LDT leaks memory and privilege. exit()Ing with an active LDT leaks memory. I guess wine doesn't change the user LDT often enough for the bugs to do more than leak memory. I'd like testing of misconfigured options to be fatal but can't see a good way to implement it. A bad way: - in opt_global.h, define each option that doesn't belong in opt_global.h as an expression with a syntax error. - redefine the expression in each opt_foo.h file (same as now, except for an #undef to prevent a warning). - change each test of an option to use `#if' to ensure an error if the expression is not defined properly. Bruce