Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757516Ab1EXUq4 (ORCPT ); Tue, 24 May 2011 16:46:56 -0400 Received: from mail-pv0-f174.google.com ([74.125.83.174]:60587 "EHLO mail-pv0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752334Ab1EXUqz (ORCPT ); Tue, 24 May 2011 16:46:55 -0400 DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=subject:from:to:cc:in-reply-to:references:content-type:date :message-id:mime-version:x-mailer:content-transfer-encoding; b=ns79DI/hItWACqq5gN2Lyzh2K1zzHhUa7ci7OaLY61+0LLoKlkbQlkLIKYbm/7kpsz YiVeaJYlDCu37V9O5jzlz8UdpipMjpZdc6usE1Mk0pSf452xdy1iANORS0ZxZn+8qMkN Db/iz9pQoGDhkpEwwcwfzA2vZSsQWNWLGXc3U= Subject: Re: [PATCH] Kconfig: add warning about permission of config file From: Hiromu Yakura To: Arnaud Lacombe Cc: Michal Marek , linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, zippel@linux-m68k.org In-Reply-To: References: <1306167401.18840.8.camel@hiromu-MacBook> <1306242400.7501.10.camel@hiromu-MacBook> <4DDBB150.2090602@suse.cz> <1306247192.7501.25.camel@hiromu-MacBook> <4DDBC846.8050402@suse.cz> <1306258716.7501.35.camel@hiromu-MacBook> Content-Type: text/plain; charset="UTF-8" Date: Wed, 25 May 2011 05:46:50 +0900 Message-ID: <1306270010.7501.43.camel@hiromu-MacBook> Mime-Version: 1.0 X-Mailer: Evolution 2.32.2 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1733 Lines: 41 On Tue, May 24, 2011, at 2:59, Arnaud Lacombe wrote: > Hi, > > On Tue, May 24, 2011 at 1:38 PM, Hiromu Yakura wrote: > > On Tue, May 24, 2011, at 0:50, Arnaud Lacombe > > wrote: > >> On Tue, May 24, 2011 at 11:01 AM, Michal Marek wrote: > >> > I see, qconf lacks a check for the return value of conf_write() in > >> > ConfigMainWindow::closeEvent(), gconf does check the return value, but only > >> > displays it in the bottom box of the main window instead of a message box. > >> > Neither of them return failure in the error case. These bugs should be > >> > indeed fixed. > >> > > >> agree. > >> > >> > But I don't like the directory permission check, it only > >> > handles one case, but does not handle permission on the .config file itself > >> > with KCONFIG_OVERWRITECONFIG=1, ENOSPC and so on. > >> > > >> seconded. > > I'm sorry for forgetting to handle a case which was set KCONFIG_OVERWRITECONFIG. > > So I rewrote the patch and attach it. > > > > Thanks for your advice. > > > > Signed-off-by: Hiromu Yakura > > > Let me re-state: your patch does not handle all the case where > conf_write() may fails, and I do not think we want to preemptively > check for all errors open(2) may return. conf_write() is called after the configure changed. So I don't think we should handle the failed case of conf_write() because the purpose of this patch is not to losing changes. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/