From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Karel Klic Newsgroups: gmane.emacs.devel Subject: Re: SELinux Bug report Date: Fri, 30 Apr 2010 16:12:26 +0200 Message-ID: <4BDAE54A.8080302@redhat.com> References: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="------------000707060009060206070605" X-Trace: dough.gmane.org 1272638501 14998 80.91.229.12 (30 Apr 2010 14:41:41 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Fri, 30 Apr 2010 14:41:41 +0000 (UTC) Cc: emacs-devel@gnu.org To: bryan.shell@beleriand.co.uk Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Apr 30 16:41:40 2010 connect(): No such file or directory Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1O7rPP-0004Qc-N3 for ged-emacs-devel@m.gmane.org; Fri, 30 Apr 2010 16:41:40 +0200 Original-Received: from localhost ([127.0.0.1]:36933 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1O7rPP-00083s-4W for ged-emacs-devel@m.gmane.org; Fri, 30 Apr 2010 10:41:39 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1O7qxJ-0002is-0W for emacs-devel@gnu.org; Fri, 30 Apr 2010 10:12:37 -0400 Original-Received: from [140.186.70.92] (port=38054 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1O7qxH-0002ho-Cv for emacs-devel@gnu.org; Fri, 30 Apr 2010 10:12:36 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1O7qxD-0001pk-88 for emacs-devel@gnu.org; Fri, 30 Apr 2010 10:12:35 -0400 Original-Received: from mx1.redhat.com ([209.132.183.28]:12418) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1O7qxD-0001pQ-0u for emacs-devel@gnu.org; Fri, 30 Apr 2010 10:12:31 -0400 Original-Received: from int-mx05.intmail.prod.int.phx2.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.18]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id o3UECSgt030425 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Fri, 30 Apr 2010 10:12:28 -0400 Original-Received: from localhost.localdomain (dhcp-29-139.brq.redhat.com [10.34.29.139]) by int-mx05.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id o3UECQGZ013623; Fri, 30 Apr 2010 10:12:27 -0400 User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1.9) Gecko/20100330 Fedora/3.0.4-1.fc12 Thunderbird/3.0.4 In-Reply-To: X-Scanned-By: MIMEDefang 2.67 on 10.5.11.18 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:124360 Archived-At: This is a multi-part message in MIME format. --------------000707060009060206070605 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Hi Bryan, the attached patch fixes the crash. Until now I have never seen context_*_get() returning NULL. Karel On 04/29/2010 11:03 PM, Bryan Shell wrote: > Hi, > > I've been have issues the current trunk and the SELinux patch(s) that > were recently applied. I'm not 100% who's issue it is but it's clear > that configuring with --without-selinux fixes the issue. I've captured > a backtrace (and have the core file if more information is needed) and > have attached that. The box I'm useing this on has a rather restrictive > policy in place, so I'm not ruling out the possiblity that it just a > configuration issue. > > Thanks > -bryan --------------000707060009060206070605 Content-Type: text/x-patch; name="emacs-selinux-getnull.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="emacs-selinux-getnull.patch" --- fileio.c.old 2010-04-30 16:01:40.955759605 +0200 +++ fileio.c 2010-04-30 16:03:45.949877364 +0200 @@ -2918,10 +2918,14 @@ if (conlength > 0) { context = context_new (con); - values[0] = build_string (context_user_get (context)); - values[1] = build_string (context_role_get (context)); - values[2] = build_string (context_type_get (context)); - values[3] = build_string (context_range_get (context)); + if (context_user_get (context)) + values[0] = build_string (context_user_get (context)); + if (context_role_get (context)) + values[1] = build_string (context_role_get (context)); + if (context_type_get (context)) + values[2] = build_string (context_type_get (context)); + if (context_range_get (context)) + values[3] = build_string (context_range_get (context)); context_free (context); } if (con) --------------000707060009060206070605--