From owner-freebsd-rc@FreeBSD.ORG Sat Dec 24 18:05:04 2011 Return-Path: Delivered-To: freebsd-rc@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3B900106566B; Sat, 24 Dec 2011 18:05:04 +0000 (UTC) (envelope-from gelraen.ua@gmail.com) Received: from mail-vx0-f182.google.com (mail-vx0-f182.google.com [209.85.220.182]) by mx1.freebsd.org (Postfix) with ESMTP id C68598FC08; Sat, 24 Dec 2011 18:05:02 +0000 (UTC) Received: by vcbfk1 with SMTP id fk1so13964317vcb.13 for ; Sat, 24 Dec 2011 10:05:02 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type:content-transfer-encoding; bh=zEA18dDHZSmdJ1SMZp2nuAFiS8d8bZc1m8znmJCblMQ=; b=jPiz2hdxHU4NOM6tDAiSU34sghM+wxUDm5hil9bxX8Aedx6iRlGdrhi5X3QNRilgFY gAHLm1DbxhzyZSbN85AJsBKeckLyHkqoUQSHKR8N5Oeg0cSNs+mrnTTBpYWb4TQFYGEb iiOA2DsHV/Ou80XwOdTev6RmzK5wq15C3NnW4= Received: by 10.220.205.194 with SMTP id fr2mr12466693vcb.44.1324749902196; Sat, 24 Dec 2011 10:05:02 -0800 (PST) MIME-Version: 1.0 Received: by 10.52.29.225 with HTTP; Sat, 24 Dec 2011 10:04:41 -0800 (PST) In-Reply-To: References: <201112241230.pBOCUF3h064098@freefall.freebsd.org> <74F7E2CE-89DC-4F64-9A50-71B9FD458025@bsdimp.com> From: Maxim Ignatenko Date: Sat, 24 Dec 2011 20:04:41 +0200 Message-ID: To: Warner Losh Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Cc: freebsd-rc@freebsd.org Subject: Re: conf/163508: [rc.subr] [patch] Add "enable" and "disable" commands to rc.subr X-BeenThere: freebsd-rc@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Discussion related to /etc/rc.d design and implementation." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 24 Dec 2011 18:05:04 -0000 On 24 December 2011 19:51, Warner Losh wrote: > > On Dec 24, 2011, at 10:29 AM, Maxim Ignatenko wrote: > >>> =C2=A0If the 5% of cases are when someone has done something complicate= d to the rc.conf file, then I don't care: they won't use this interface and= we can detect this case and do nothing. >> >> Now I don't see how to distinguish cases when ${rcvar} set to default >> value in rc-script and when it's set in other file in some not obvious >> way. > > What does that matter? > In second case it should say something like "Unable to find where ${rcvar} was set". Now it adds ${rcvar}=3DYES to last included file in both cases. This still should correctly enable or disable some service unless /etc/rc.subr was modified to include some another file later, but, as I understood, this is what was meant by "corner case handling".